diff --git a/llvm/lib/MC/MCParser/MasmParser.cpp b/llvm/lib/MC/MCParser/MasmParser.cpp --- a/llvm/lib/MC/MCParser/MasmParser.cpp +++ b/llvm/lib/MC/MCParser/MasmParser.cpp @@ -4467,8 +4467,9 @@ return addErrorSuffix(" in align directive"); // Ignore empty 'align' directives. if (getTok().is(AsmToken::EndOfStatement)) { - Warning(AlignmentLoc, "align directive with no operand is ignored"); - return parseToken(AsmToken::EndOfStatement); + return Warning(AlignmentLoc, + "align directive with no operand is ignored") && + parseToken(AsmToken::EndOfStatement); } if (parseAbsoluteExpression(Alignment) || parseToken(AsmToken::EndOfStatement))