llvm.org GIT mirror llvm / 5dd4b9f
MC: loosen an overzealous assertion Permit active macro expansions when terminating the assembler if there were errors during the expansion. This would only trigger on invalid input when built with assertions. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@209309 91177308-0d34-0410-b5e6-96231b3b80d8 Saleem Abdulrasool 6 years ago
2 changed file(s) with 12 addition(s) and 1 deletion(s). Raw diff Collapse all Expand all
527527 }
528528
529529 AsmParser::~AsmParser() {
530 assert(ActiveMacros.empty() && "Unexpected active macro instantiation!");
530 assert((HadError || ActiveMacros.empty()) &&
531 "Unexpected active macro instantiation!");
531532
532533 // Destroy any macros.
533534 for (StringMap::iterator it = MacroMap.begin(),
0 // RUN: not llvm-mc -triple i686-linux -o /dev/null %s
1 // REQUIRES: asserts
2
3 .macro macro parameter=0
4 .if \parameter
5 .else
6 .endm
7
8 macro 1
9