forked from OSchip/llvm-project
ARM64AsmParser.cpp: Fix vg_leak in MC/ARM64/fp-encoding.s.
llvm-svn: 206279
This commit is contained in:
parent
a3e4cebd96
commit
6091e1aed5
|
@ -4218,6 +4218,7 @@ bool ARM64AsmParser::MatchAndEmitInstruction(SMLoc IDLoc, unsigned &Opcode,
|
|||
if (Op->isVectorIndexD() && Op->getVectorIndex() == 1) {
|
||||
SMLoc Loc = Op->getStartLoc();
|
||||
Operands.pop_back();
|
||||
delete Op;
|
||||
Operands.push_back(
|
||||
ARM64Operand::CreateToken("[", false, Loc, getContext()));
|
||||
Operands.push_back(
|
||||
|
@ -4239,6 +4240,7 @@ bool ARM64AsmParser::MatchAndEmitInstruction(SMLoc IDLoc, unsigned &Opcode,
|
|||
Operands.insert(
|
||||
Operands.begin() + OpNo + 2,
|
||||
ARM64Operand::CreateToken("]", false, Loc, getContext()));
|
||||
delete Op;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue