Index: llvm/lib/MC/MCParser/AsmParser.cpp =================================================================== --- llvm/lib/MC/MCParser/AsmParser.cpp +++ llvm/lib/MC/MCParser/AsmParser.cpp @@ -5885,6 +5885,8 @@ SMLoc EqualLoc = Parser.getTok().getLoc(); if (Parser.parseExpression(Value)) return Parser.TokError("missing expression"); + if (Name.empty()) + return Parser.TokError("Symbol name cannot be empty"); // Note: we don't count b as used in "a = b". This is to allow // a = b