Down with _even more_ statics!
llvm-svn: 74137
diff --git a/llvm/lib/CodeGen/AsmPrinter/DIE.cpp b/llvm/lib/CodeGen/AsmPrinter/DIE.cpp
index dc149cf..01c431c 100644
--- a/llvm/lib/CodeGen/AsmPrinter/DIE.cpp
+++ b/llvm/lib/CodeGen/AsmPrinter/DIE.cpp
@@ -126,7 +126,6 @@
#ifndef NDEBUG
void DIE::print(std::ostream &O, unsigned IncIndent) {
- static unsigned IndentCount = 0;
IndentCount += IncIndent;
const std::string Indent(IndentCount, ' ');
bool isBlock = Abbrev.getTag() == 0;
diff --git a/llvm/lib/CodeGen/AsmPrinter/DIE.h b/llvm/lib/CodeGen/AsmPrinter/DIE.h
index b14d91c..5b60327 100644
--- a/llvm/lib/CodeGen/AsmPrinter/DIE.h
+++ b/llvm/lib/CodeGen/AsmPrinter/DIE.h
@@ -141,9 +141,13 @@
/// Abstract compile unit.
CompileUnit *AbstractCU;
+
+ // Private data for print()
+ mutable unsigned IndentCount;
public:
explicit DIE(unsigned Tag)
- : Abbrev(Tag, dwarf::DW_CHILDREN_no), Offset(0), Size(0) {}
+ : Abbrev(Tag, dwarf::DW_CHILDREN_no), Offset(0),
+ Size(0), IndentCount(0) {}
virtual ~DIE();
// Accessors.