diff options
Diffstat (limited to 'llvm/lib')
| -rw-r--r-- | llvm/lib/TableGen/TGParser.cpp | 5 | 
1 files changed, 4 insertions, 1 deletions
diff --git a/llvm/lib/TableGen/TGParser.cpp b/llvm/lib/TableGen/TGParser.cpp index 54932487e8d..a9de4eac9d3 100644 --- a/llvm/lib/TableGen/TGParser.cpp +++ b/llvm/lib/TableGen/TGParser.cpp @@ -1734,7 +1734,10 @@ Init *TGParser::ParseDeclaration(Record *CurRec,      Init *Val = ParseValue(CurRec, Type);      if (!Val ||          SetValue(CurRec, ValLoc, DeclName, std::vector<unsigned>(), Val)) -      return nullptr; +      // Return the name, even if an error is thrown.  This is so that we can +      // continue to make some progress, even without the value having been +      // initialized. +      return DeclName;    }    return DeclName;  | 

