mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-03-02 22:32:08 +00:00
AsmParser: extractvalue requires at least one index operand
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@229365 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
40d10639cf
commit
415561b6e0
@ -1633,6 +1633,7 @@ bool LLParser::ParseIndexList(SmallVectorImpl<unsigned> &Indices,
|
||||
|
||||
while (EatIfPresent(lltok::comma)) {
|
||||
if (Lex.getKind() == lltok::MetadataVar) {
|
||||
if (Indices.empty()) return TokError("expected index");
|
||||
AteExtraComma = true;
|
||||
return false;
|
||||
}
|
||||
|
8
test/Assembler/extractvalue-no-idx.ll
Normal file
8
test/Assembler/extractvalue-no-idx.ll
Normal file
@ -0,0 +1,8 @@
|
||||
; RUN: not llvm-as < %s 2>&1 | FileCheck %s
|
||||
|
||||
; CHECK: expected index
|
||||
|
||||
define void @f1() {
|
||||
extractvalue <{ i32, i32 }> undef, !dbg !0
|
||||
ret void
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user