forked from OSchip/llvm-project
[mlir][ods] NFC fix tblgen crash with empty assembly format
This commit is contained in:
parent
d379ec9908
commit
72619d101f
|
@ -812,6 +812,8 @@ LogicalResult DefFormatParser::verify(SMLoc loc,
|
||||||
it.value().getName());
|
it.value().getName());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (elements.empty())
|
||||||
|
return success();
|
||||||
// A `struct` directive that contains optional parameters cannot be followed
|
// A `struct` directive that contains optional parameters cannot be followed
|
||||||
// by a comma literal, which is ambiguous.
|
// by a comma literal, which is ambiguous.
|
||||||
for (auto it : llvm::zip(elements.drop_back(), elements.drop_front())) {
|
for (auto it : llvm::zip(elements.drop_back(), elements.drop_front())) {
|
||||||
|
|
Loading…
Reference in New Issue