summaryrefslogtreecommitdiffstats
path: root/llvm/lib/ObjectYAML/DWARFEmitter.cpp
diff options
context:
space:
mode:
authorBenjamin Kramer <benny.kra@googlemail.com>2017-08-20 13:03:48 +0000
committerBenjamin Kramer <benny.kra@googlemail.com>2017-08-20 13:03:48 +0000
commit49a49fe816122f9bc4cf8f909e0bc24aa84ea4ce (patch)
treef67fcbe4d22d0268902ea501339f083eab383c62 /llvm/lib/ObjectYAML/DWARFEmitter.cpp
parentdf8c2628ac6778024d6b99484bb94fd77e466d0e (diff)
downloadbcm5719-llvm-49a49fe816122f9bc4cf8f909e0bc24aa84ea4ce.tar.gz
bcm5719-llvm-49a49fe816122f9bc4cf8f909e0bc24aa84ea4ce.zip
Move helper classes into anonymous namespaces.
No functionality change intended. llvm-svn: 311288
Diffstat (limited to 'llvm/lib/ObjectYAML/DWARFEmitter.cpp')
-rw-r--r--llvm/lib/ObjectYAML/DWARFEmitter.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/llvm/lib/ObjectYAML/DWARFEmitter.cpp b/llvm/lib/ObjectYAML/DWARFEmitter.cpp
index 89fc652035c..c49c2249cdf 100644
--- a/llvm/lib/ObjectYAML/DWARFEmitter.cpp
+++ b/llvm/lib/ObjectYAML/DWARFEmitter.cpp
@@ -62,8 +62,8 @@ static void ZeroFillBytes(raw_ostream &OS, size_t Size) {
OS.write(reinterpret_cast<char *>(FillData.data()), Size);
}
-void writeInitialLength(const DWARFYAML::InitialLength &Length, raw_ostream &OS,
- bool IsLittleEndian) {
+static void writeInitialLength(const DWARFYAML::InitialLength &Length,
+ raw_ostream &OS, bool IsLittleEndian) {
writeInteger((uint32_t)Length.TotalLength, OS, IsLittleEndian);
if (Length.isDWARF64())
writeInteger((uint64_t)Length.TotalLength64, OS, IsLittleEndian);
@@ -131,6 +131,7 @@ void DWARFYAML::EmitPubSection(raw_ostream &OS,
}
}
+namespace {
/// \brief An extension of the DWARFYAML::ConstVisitor which writes compile
/// units and DIEs to a stream.
class DumpVisitor : public DWARFYAML::ConstVisitor {
@@ -195,6 +196,7 @@ public:
DumpVisitor(const DWARFYAML::Data &DI, raw_ostream &Out)
: DWARFYAML::ConstVisitor(DI), OS(Out) {}
};
+} // namespace
void DWARFYAML::EmitDebugInfo(raw_ostream &OS, const DWARFYAML::Data &DI) {
DumpVisitor Visitor(DI, OS);
OpenPOWER on IntegriCloud