Skip to content

Commit 0e199e4

Browse files
committed
Add a tblgen test case
1 parent 61fa5c2 commit 0e199e4

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

mlir/test/mlir-tblgen/op-python-bindings.td

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -252,6 +252,32 @@ def DeriveResultTypesVariadicOp : TestOp<"derive_result_types_variadic_op", [Fir
252252
// CHECK: def derive_result_types_variadic_op(res, _gen_res_1, type_, *, loc=None, ip=None)
253253
// CHECK: return _get_op_result_or_op_results(DeriveResultTypesVariadicOp(res=res, _gen_res_1=_gen_res_1, type_=type_, loc=loc, ip=ip))
254254

255+
256+
// CHECK: class DescriptionOp(_ods_ir.OpView):
257+
// CHECK: """
258+
// CHECK: This is a long description.
259+
// CHECK: It has multiple lines.
260+
// CHECK: A code block (to test the indent).
261+
// CHECK: ```mlir
262+
// CHECK: test.loop {
263+
// CHECK: test.yield
264+
// CHECK: }
265+
// CHECK: ```
266+
// CHECK: """
267+
def DescriptionOp : TestOp<"description"> {
268+
let description = [{
269+
This is a long description.
270+
It has multiple lines.
271+
272+
A code block (to test the indent).
273+
```mlir
274+
test.loop {
275+
test.yield
276+
}
277+
```
278+
}];
279+
}
280+
255281
// CHECK: @_ods_cext.register_operation(_Dialect)
256282
// CHECK: class EmptyOp(_ods_ir.OpView):
257283
// CHECK-LABEL: OPERATION_NAME = "test.empty"

0 commit comments

Comments
 (0)