projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7efe936
)
Fix Name Access
author
David Greene
<greened@obbligato.org>
Wed, 19 Oct 2011 13:03:45 +0000
(13:03 +0000)
committer
David Greene
<greened@obbligato.org>
Wed, 19 Oct 2011 13:03:45 +0000
(13:03 +0000)
Get the Record name by string explicitly to avoid potential asserts.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142514
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/TableGen/TGParser.cpp
patch
|
blob
|
history
diff --git
a/lib/TableGen/TGParser.cpp
b/lib/TableGen/TGParser.cpp
index e913bce705ab840ee461e7afa81e4dda01ffef75..5dc25e9827a6c54397a49ef6f3191fa51f67e874 100644
(file)
--- a/
lib/TableGen/TGParser.cpp
+++ b/
lib/TableGen/TGParser.cpp
@@
-1686,7
+1686,8
@@
bool TGParser::ParseDef(MultiClass *CurMultiClass) {
// Ensure redefinition doesn't happen.
if (Records.getDef(CurRec->getName())) {
- Error(DefLoc, "def '" + CurRec->getName() + "' already defined");
+ Error(DefLoc, "def '" + CurRec->getNameInitAsString()
+ + "' already defined");
return true;
}
Records.addDef(CurRec);