mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-11-01 15:11:24 +00:00
Fixed edis to tokenize instructions with no
operands correctly. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102227 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
37ff5c66db
commit
a870256d7d
@ -368,12 +368,14 @@ int EDDisassembler::parseInst(SmallVectorImpl<MCParsedAsmOperand*> &operands,
|
||||
OwningPtr<TargetAsmParser> TargetParser(Tgt->createAsmParser(genericParser));
|
||||
|
||||
AsmToken OpcodeToken = genericParser.Lex();
|
||||
genericParser.Lex(); // consume next token, because specificParser expects us to
|
||||
|
||||
AsmToken NextToken = genericParser.Lex(); // consume next token, because specificParser expects us to
|
||||
|
||||
if (OpcodeToken.is(AsmToken::Identifier)) {
|
||||
instName = OpcodeToken.getString();
|
||||
instLoc = OpcodeToken.getLoc();
|
||||
if (TargetParser->ParseInstruction(instName, instLoc, operands))
|
||||
|
||||
if (NextToken.isNot(AsmToken::Eof) &&
|
||||
TargetParser->ParseInstruction(instName, instLoc, operands))
|
||||
ret = -1;
|
||||
} else {
|
||||
ret = -1;
|
||||
|
Loading…
Reference in New Issue
Block a user