[clang-tidy][NFC]remove deps of clang in clang tidy test (#116588)
[llvm-project.git] / mlir / test / mlir-tblgen / testdialect-attrdefs.mlir
blob89ad3594eebd83a3b3fdf62e7083a4cc83680737
1 // RUN: mlir-opt %s -split-input-file -verify-diagnostics | FileCheck %s
3 // CHECK-LABEL: func private @compoundA()
4 // CHECK-SAME: #test.cmpnd_a<1, !test.smpla, [5, 6]>
5 func.func private @compoundA() attributes {foo = #test.cmpnd_a<1, !test.smpla, [5, 6]>}
7 // CHECK: test.result_has_same_type_as_attr #test.attr_with_self_type_param : i32 -> i32
8 %a = test.result_has_same_type_as_attr #test.attr_with_self_type_param : i32 -> i32
10 // CHECK: test.result_has_same_type_as_attr #test<attr_with_type_builder 10 : i16> : i16 -> i16
11 %b = test.result_has_same_type_as_attr #test<attr_with_type_builder 10 : i16> -> i16
13 // CHECK-LABEL: @qualifiedAttr()
14 // CHECK-SAME: #test.cmpnd_nested_outer_qual<i #test.cmpnd_nested_inner<42 <1, !test.smpla, [5, 6]>>>
15 func.func private @qualifiedAttr() attributes {foo = #test.cmpnd_nested_outer_qual<i #test.cmpnd_nested_inner<42 <1, !test.smpla, [5, 6]>>>}
17 // CHECK-LABEL: @overriddenAttr
18 // CHECK-SAME: foo = 5 : index
19 func.func private @overriddenAttr() attributes {
20   foo = #test.override_builder<5>
23 // CHECK-LABEL: @decimalIntegerShapeEmpty
24 // CHECK-SAME: foo = #test.decimal_shape<>
25 func.func private @decimalIntegerShapeEmpty() attributes {
26   foo = #test.decimal_shape<>
29 // CHECK-LABEL: @decimalIntegerShape
30 // CHECK-SAME: foo = #test.decimal_shape<5>
31 func.func private @decimalIntegerShape() attributes {
32   foo = #test.decimal_shape<5>
35 // CHECK-LABEL: @decimalIntegerShapeMultiple
36 // CHECK-SAME: foo = #test.decimal_shape<0x3x7>
37 func.func private @decimalIntegerShapeMultiple() attributes {
38   foo = #test.decimal_shape<0x3x7>
41 // -----
43 func.func private @hexdecimalInteger() attributes {
44 // expected-error @below {{expected an integer}}
45   sdg = #test.decimal_shape<1x0xb>