1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 11:13:28 +01:00

Fix Record Name Reference

Get the record name though the init to avoid an assert.

llvm-svn: 149153
This commit is contained in:
David Greene 2012-01-28 00:03:24 +00:00
parent bbf83feb7f
commit 7748b4cf3b

View File

@ -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;