- if (getLexer().is(AsmToken::Dollar)) {
- MCSymbol *Symbol;
- SMLoc DollarLoc = getLexer().getLoc();
- // Consume the dollar sign, and check for a following identifier.
- Parser.Lex();
- // We have a '$' followed by something, make sure they are adjacent.
- if (DollarLoc.getPointer() + 1 != getTok().getLoc().getPointer())
- return true;
- StringRef Res =
- StringRef(DollarLoc.getPointer(),
- getTok().getEndLoc().getPointer() - DollarLoc.getPointer());
- Symbol = getContext().GetOrCreateSymbol(Res);
- Parser.Lex();
- Value =
- MCSymbolRefExpr::Create(Symbol, MCSymbolRefExpr::VK_None, getContext());
- } else if (Parser.parseExpression(Value))