From 7d602f7a77fd099bd7936dba70fba4e93b68dd5f Mon Sep 17 00:00:00 2001 From: Artyom Skrobov Date: Sun, 20 Jul 2014 12:08:28 +0000 Subject: [PATCH] Namespace cleanup (no functional change) llvm-svn: 213478 --- llvm/lib/Object/MachOObjectFile.cpp | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) diff --git a/llvm/lib/Object/MachOObjectFile.cpp b/llvm/lib/Object/MachOObjectFile.cpp index f7384e0..51c4c33 100644 --- a/llvm/lib/Object/MachOObjectFile.cpp +++ b/llvm/lib/Object/MachOObjectFile.cpp @@ -27,17 +27,15 @@ using namespace llvm; using namespace object; -namespace llvm { - -namespace object { - -struct section_base { - char sectname[16]; - char segname[16]; -}; +namespace { + struct section_base { + char sectname[16]; + char segname[16]; + }; +} template -T getStruct(const MachOObjectFile *O, const char *P) { +static T getStruct(const MachOObjectFile *O, const char *P) { T Cmd; memcpy(&Cmd, P, sizeof(T)); if (O->isLittleEndian() != sys::IsLittleEndianHost) @@ -1745,5 +1743,3 @@ ObjectFile::createMachOObjectFile(std::unique_ptr &Buffer) { return Ret.release(); } -} // end namespace object -} // end namespace llvm -- 2.7.4