aboutsummaryrefslogtreecommitdiffstats
path: root/utils
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2002-12-06 04:42:16 +0000
committerChris Lattner <sabre@nondot.org>2002-12-06 04:42:16 +0000
commit28c2d409a5551b117da97defe168620ab525bfe0 (patch)
tree29630a032cceee280a5b3d2dc5f6dcdb5f0245d4 /utils
parent23ffa4a48820e58b411cf94a66b2a0d91173fbfa (diff)
downloadexternal_llvm-28c2d409a5551b117da97defe168620ab525bfe0.zip
external_llvm-28c2d409a5551b117da97defe168620ab525bfe0.tar.gz
external_llvm-28c2d409a5551b117da97defe168620ab525bfe0.tar.bz2
Fix bug
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4942 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'utils')
-rw-r--r--utils/TableGen/FileParser.y4
1 files changed, 2 insertions, 2 deletions
diff --git a/utils/TableGen/FileParser.y b/utils/TableGen/FileParser.y
index ff3ec40..76f07e4 100644
--- a/utils/TableGen/FileParser.y
+++ b/utils/TableGen/FileParser.y
@@ -92,8 +92,8 @@ static void setValue(const std::string &ValName,
// Loop over bits, assigning values as appropriate...
for (unsigned i = 0, e = BitList->size(); i != e; ++i) {
unsigned Bit = (*BitList)[i];
- if (NewVal->getBit(i)) {
- err() << "Cannot set bit #" << i << " of value '" << ValName
+ if (NewVal->getBit(Bit)) {
+ err() << "Cannot set bit #" << Bit << " of value '" << ValName
<< "' more than once!\n";
abort();
}