diff options
author | Chad Rosier <mcrosier@apple.com> | 2013-02-15 21:58:13 +0000 |
---|---|---|
committer | Chad Rosier <mcrosier@apple.com> | 2013-02-15 21:58:13 +0000 |
commit | 4fb25b7d799ea27a2c98a4d9bcf7469cc685db47 (patch) | |
tree | e3863392a10c7b7af771ed8027aeedb2a51f96e0 /lib/Target/X86 | |
parent | b3dedc2ef26fd3c5ee5d14e5ef10d6dcf44fedd7 (diff) | |
download | external_llvm-4fb25b7d799ea27a2c98a4d9bcf7469cc685db47.zip external_llvm-4fb25b7d799ea27a2c98a4d9bcf7469cc685db47.tar.gz external_llvm-4fb25b7d799ea27a2c98a4d9bcf7469cc685db47.tar.bz2 |
[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
Diffstat (limited to 'lib/Target/X86')
-rw-r--r-- | lib/Target/X86/AsmParser/X86AsmParser.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Target/X86/AsmParser/X86AsmParser.cpp b/lib/Target/X86/AsmParser/X86AsmParser.cpp index dc15a11..8c4c447 100644 --- a/lib/Target/X86/AsmParser/X86AsmParser.cpp +++ b/lib/Target/X86/AsmParser/X86AsmParser.cpp @@ -911,7 +911,8 @@ X86Operand *X86AsmParser::ParseIntelBracExpression(unsigned SegReg, if (getLexer().isNot(AsmToken::RBrac)) 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(); return X86Operand::CreateMem(Disp, Start, End, Size); } |