aboutsummaryrefslogtreecommitdiffstats
path: root/utils
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2002-12-06 04:42:10 +0000
committerChris Lattner <sabre@nondot.org>2002-12-06 04:42:10 +0000
commit23ffa4a48820e58b411cf94a66b2a0d91173fbfa (patch)
tree8f224fd5bb52325adf9dd39e41d155a50d92c643 /utils
parentcdbfa422cd7aadd7f6c7160133bb264c26f504ce (diff)
downloadexternal_llvm-23ffa4a48820e58b411cf94a66b2a0d91173fbfa.zip
external_llvm-23ffa4a48820e58b411cf94a66b2a0d91173fbfa.tar.gz
external_llvm-23ffa4a48820e58b411cf94a66b2a0d91173fbfa.tar.bz2
Allow printing partially constructed bitsets
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4941 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'utils')
-rw-r--r--utils/TableGen/Record.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/utils/TableGen/Record.cpp b/utils/TableGen/Record.cpp
index b33e5e7..469faa9 100644
--- a/utils/TableGen/Record.cpp
+++ b/utils/TableGen/Record.cpp
@@ -153,7 +153,10 @@ void BitsInit::print(std::ostream &OS) const {
OS << "{ ";
for (unsigned i = 0, e = getNumBits(); i != e; ++i) {
if (i) OS << ", ";
- getBit(e-i-1)->print(OS);
+ if (Init *Bit = getBit(e-i-1))
+ Bit->print(OS);
+ else
+ OS << "*";
}
OS << " }";
}