diff options
author | David Greene <greened@obbligato.org> | 2012-01-28 00:03:24 +0000 |
---|---|---|
committer | David Greene <greened@obbligato.org> | 2012-01-28 00:03:24 +0000 |
commit | 1d5013992f8ecf5cc670ab8a1a599db4722c2f5d (patch) | |
tree | e51503cd79453af255c778e7b60285ee5bcd124d /lib/TableGen/TGParser.cpp | |
parent | 3f8d3c7d72367244e56efd9ce2c64ef5905cb377 (diff) |
Fix Record Name Reference
Get the record name though the init to avoid an assert.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149153 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/TableGen/TGParser.cpp')
-rw-r--r-- | lib/TableGen/TGParser.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/TableGen/TGParser.cpp b/lib/TableGen/TGParser.cpp index 13a752e3a2..0f64f4bcda 100644 --- a/lib/TableGen/TGParser.cpp +++ b/lib/TableGen/TGParser.cpp @@ -1775,7 +1775,7 @@ bool TGParser::ParseDef(MultiClass *CurMultiClass) { // Top-level def definition. // Ensure redefinition doesn't happen. - if (Records.getDef(CurRec->getName())) { + if (Records.getDef(CurRec->getNameInitAsString())) { Error(DefLoc, "def '" + CurRec->getNameInitAsString() + "' already defined"); return true; |