Sketch out parser/IR support for OperationInst, and a new Instruction base
class.
Introduce an Identifier class to MLIRContext to represent uniqued identifiers,
introduce string literal support to the lexer, introducing parser and printer
support etc.
PiperOrigin-RevId: 202592007
diff --git a/test/IR/parser-errors.mlir b/test/IR/parser-errors.mlir
index e60bf78..408fe13 100644
--- a/test/IR/parser-errors.mlir
+++ b/test/IR/parser-errors.mlir
@@ -44,7 +44,7 @@
bb40:
return
bb41:
-bb42: ; expected-error {{expected terminator}}
+bb42: ; expected-error {{expected operation name}}
return
}
@@ -57,3 +57,21 @@
mlfunc @no_return() {
} ; expected-error {{ML function must end with return statement}}
+
+; -----
+
+" ; expected-error {{expected}}
+"
+
+; -----
+
+" ; expected-error {{expected}}
+
+; -----
+
+cfgfunc @no_terminator() {
+bb40:
+ "foo"()
+ ""() ; expected-error {{empty operation name is invalid}}
+ return
+}