HomePhabricator

[MLIR] Change FuncOp assembly syntax to print visibility inline instead of in…

Authored by jurahul on Nov 9 2020, 8:23 AM.

Description

[MLIR] Change FuncOp assembly syntax to print visibility inline instead of in attrib dict.

  • Change syntax for FuncOp to be func <visibility>? @name instead of printing the visibility in the attribute dictionary.
  • Since printFunctionLikeOp() and parseFunctionLikeOp() are also used by other operations, make the "inline visibility" an opt-in feature.
  • Updated unit test to use and check the new syntax.

Differential Revision: https://reviews.llvm.org/D90859