mirror of
https://github.com/RPCS3/llvm.git
synced 2025-01-02 17:58:26 +00:00
[ms-inline asm] Adjust the EndLoc to account for the ']'.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@175312 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
b3dedc2ef2
commit
4fb25b7d79
@ -911,7 +911,8 @@ X86Operand *X86AsmParser::ParseIntelBracExpression(unsigned SegReg,
|
|||||||
|
|
||||||
if (getLexer().isNot(AsmToken::RBrac))
|
if (getLexer().isNot(AsmToken::RBrac))
|
||||||
return ErrorOperand(Parser.getTok().getLoc(), "Expected ']' token!");
|
return ErrorOperand(Parser.getTok().getLoc(), "Expected ']' token!");
|
||||||
End = Parser.getTok().getEndLoc();
|
// Adjust the EndLoc due to the ']'.
|
||||||
|
End = SMLoc::getFromPointer(Parser.getTok().getEndLoc().getPointer()-1);
|
||||||
Parser.Lex();
|
Parser.Lex();
|
||||||
return X86Operand::CreateMem(Disp, Start, End, Size);
|
return X86Operand::CreateMem(Disp, Start, End, Size);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user