lld: Handle parsing AT(ADDR(.foo-bar)).

The problem we had with it is that anything inside an AT is an
expression, so we failed to parse the section name because of the - in
it.

Requested by:	royger
Obtained from:	LLVM r322801 by Rafael Espindola
This commit is contained in:
emaste 2018-01-18 21:39:19 +00:00
parent 2fba69a43f
commit d021a9004a

View File

@ -930,7 +930,10 @@ ByteCommand *ScriptParser::readByteCommand(StringRef Tok) {
StringRef ScriptParser::readParenLiteral() {
expect("(");
bool Orig = InExpr;
InExpr = false;
StringRef Tok = next();
InExpr = Orig;
expect(")");
return Tok;
}