mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-28 19:31:58 +00:00
MC/AsmLexer: Fix bug in source location for Slash token.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@117298 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
048a19abe6
commit
bdf90d679b
@ -119,7 +119,7 @@ AsmToken AsmLexer::LexSlash() {
|
|||||||
switch (*CurPtr) {
|
switch (*CurPtr) {
|
||||||
case '*': break; // C style comment.
|
case '*': break; // C style comment.
|
||||||
case '/': return ++CurPtr, LexLineComment();
|
case '/': return ++CurPtr, LexLineComment();
|
||||||
default: return AsmToken(AsmToken::Slash, StringRef(CurPtr, 1));
|
default: return AsmToken(AsmToken::Slash, StringRef(CurPtr-1, 1));
|
||||||
}
|
}
|
||||||
|
|
||||||
// C Style comment.
|
// C Style comment.
|
||||||
|
@ -19,9 +19,8 @@ k:
|
|||||||
check_expr +1, 1
|
check_expr +1, 1
|
||||||
check_expr 1 + 2, 3
|
check_expr 1 + 2, 3
|
||||||
check_expr 1 & 3, 1
|
check_expr 1 & 3, 1
|
||||||
// FIXME: There is a bug here in macro expansion.
|
check_expr 4 / 2, 2
|
||||||
.byte 4 / 2
|
check_expr 4 / -2, -2
|
||||||
.byte 4 / -2
|
|
||||||
check_expr 1 == 1, 1
|
check_expr 1 == 1, 1
|
||||||
check_expr 1 == 0, 0
|
check_expr 1 == 0, 0
|
||||||
check_expr 1 > 0, 1
|
check_expr 1 > 0, 1
|
||||||
|
Loading…
Reference in New Issue
Block a user