Use consistent spacing before custom directives for op and attr/type assemblyFormat.
Currently, assemblyFormat `custom<A>($a) custom<B>($b)` has different spacing if used for Ops vs Attrs/Types. Ops insert a space if needed before the custom directive, while attributes and types do not. This leads to the following two patterns in attributes / types: ``` # 1. Whitespace literal let assemblyFormat = "... ` ` custom<A>($a)" # 2. Custom printer code includes spacing void printB(...) { printer << ' ' << b; } ``` Moving this spacing into the generated code allows for some cleanup in mlir and improves the consistency of custom directives. Reviewed By: mehdi_amini Differential Revision: https://reviews.llvm.org/D138235
Loading
Please sign in to comment