Skip to content

Commit 300da9c

Browse files
committed
compiletest: pass -Zui-testing to rustc
1 parent 50019a7 commit 300da9c

36 files changed

+2008
-2007
lines changed

tests/compiletests/src/main.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,7 @@ impl Runner {
128128
"-Zunstable-options",
129129
"-Zcrate-attr=no_std",
130130
"-Zcrate-attr=feature(asm_experimental_arch)",
131+
"-Zui-testing",
131132
]
132133
.join(" ")
133134
}

tests/compiletests/ui/arch/debug_printf_type_checking.stderr

Lines changed: 98 additions & 98 deletions
Original file line numberDiff line numberDiff line change
@@ -1,167 +1,167 @@
11
error: Unterminated format specifier: missing type after precision
22
--> $DIR/debug_printf_type_checking.rs:11:23
33
|
4-
11 | debug_printf!("%1");
4+
LL | debug_printf!("%1");
55
| ^^^^
66

77
error: Unterminated format specifier: missing type after decimal point
88
--> $DIR/debug_printf_type_checking.rs:12:23
99
|
10-
12 | debug_printf!("%1.");
10+
LL | debug_printf!("%1.");
1111
| ^^^^^
1212

1313
error: Unrecognised format specifier: '.'
1414
--> $DIR/debug_printf_type_checking.rs:13:23
1515
|
16-
13 | debug_printf!("%.");
16+
LL | debug_printf!("%.");
1717
| ^^^^
1818

1919
error: Unrecognised format specifier: '.'
2020
--> $DIR/debug_printf_type_checking.rs:14:23
2121
|
22-
14 | debug_printf!("%.1");
22+
LL | debug_printf!("%.1");
2323
| ^^^^^
2424

2525
error: Unterminated format specifier: missing type after fraction precision
2626
--> $DIR/debug_printf_type_checking.rs:15:23
2727
|
28-
15 | debug_printf!("%1.1");
28+
LL | debug_printf!("%1.1");
2929
| ^^^^^^
3030

3131
error: Missing vector dimensions specifier
3232
--> $DIR/debug_printf_type_checking.rs:16:23
3333
|
34-
16 | debug_printf!("%1.1v");
34+
LL | debug_printf!("%1.1v");
3535
| ^^^^^^^
3636

3737
error: Invalid width for vector: 5
3838
--> $DIR/debug_printf_type_checking.rs:17:23
3939
|
40-
17 | debug_printf!("%1.1v5");
40+
LL | debug_printf!("%1.1v5");
4141
| ^^^^^^^^
4242

4343
error: Missing vector type specifier
4444
--> $DIR/debug_printf_type_checking.rs:18:23
4545
|
46-
18 | debug_printf!("%1.1v2");
46+
LL | debug_printf!("%1.1v2");
4747
| ^^^^^^^^
4848

4949
error: Unrecognised vector type specifier: 'r'
5050
--> $DIR/debug_printf_type_checking.rs:19:23
5151
|
52-
19 | debug_printf!("%1.1v2r");
52+
LL | debug_printf!("%1.1v2r");
5353
| ^^^^^^^^^
5454

5555
error: Unrecognised format specifier: 'r'
5656
--> $DIR/debug_printf_type_checking.rs:20:23
5757
|
58-
20 | debug_printf!("%r", 11_i32);
58+
LL | debug_printf!("%r", 11_i32);
5959
| ^^^^
6060

6161
error[E0308]: mismatched types
62-
--> $DIR/debug_printf_type_checking.rs:21:29
63-
|
64-
21 | debug_printf!("%f", 11_u32);
65-
| --------------------^^^^^^-
66-
| | |
67-
| | expected `f32`, found `u32`
68-
| arguments to this function are incorrect
69-
|
62+
--> $DIR/debug_printf_type_checking.rs:21:29
63+
|
64+
LL | debug_printf!("%f", 11_u32);
65+
| --------------------^^^^^^-
66+
| | |
67+
| | expected `f32`, found `u32`
68+
| arguments to this function are incorrect
69+
|
7070
help: the return type of this call is `u32` due to the type of the argument passed
71-
--> $DIR/debug_printf_type_checking.rs:21:9
72-
|
73-
21 | debug_printf!("%f", 11_u32);
74-
| ^^^^^^^^^^^^^^^^^^^^------^
75-
| |
76-
| this argument influences the return type of `debug_printf_assert_is_type`
71+
--> $DIR/debug_printf_type_checking.rs:21:9
72+
|
73+
LL | debug_printf!("%f", 11_u32);
74+
| ^^^^^^^^^^^^^^^^^^^^------^
75+
| |
76+
| this argument influences the return type of `debug_printf_assert_is_type`
7777
note: function defined here
78-
--> $SPIRV_STD_SRC/lib.rs:134:8
79-
|
80-
134 | pub fn debug_printf_assert_is_type<T>(ty: T) -> T {
81-
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
82-
= note: this error originates in the macro `debug_printf` (in Nightly builds, run with -Z macro-backtrace for more info)
78+
--> $SPIRV_STD_SRC/lib.rs:134:8
79+
|
80+
LL | pub fn debug_printf_assert_is_type<T>(ty: T) -> T {
81+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
82+
= note: this error originates in the macro `debug_printf` (in Nightly builds, run with -Z macro-backtrace for more info)
8383
help: change the type of the numeric literal from `u32` to `f32`
84-
|
85-
21 - debug_printf!("%f", 11_u32);
86-
21 + debug_printf!("%f", 11_f32);
87-
|
84+
|
85+
LL - debug_printf!("%f", 11_u32);
86+
LL + debug_printf!("%f", 11_f32);
87+
|
8888

8989
error[E0308]: mismatched types
90-
--> $DIR/debug_printf_type_checking.rs:22:29
91-
|
92-
22 | debug_printf!("%u", 11.0_f32);
93-
| --------------------^^^^^^^^-
94-
| | |
95-
| | expected `u32`, found `f32`
96-
| arguments to this function are incorrect
97-
|
90+
--> $DIR/debug_printf_type_checking.rs:22:29
91+
|
92+
LL | debug_printf!("%u", 11.0_f32);
93+
| --------------------^^^^^^^^-
94+
| | |
95+
| | expected `u32`, found `f32`
96+
| arguments to this function are incorrect
97+
|
9898
help: the return type of this call is `f32` due to the type of the argument passed
99-
--> $DIR/debug_printf_type_checking.rs:22:9
100-
|
101-
22 | debug_printf!("%u", 11.0_f32);
102-
| ^^^^^^^^^^^^^^^^^^^^--------^
103-
| |
104-
| this argument influences the return type of `debug_printf_assert_is_type`
99+
--> $DIR/debug_printf_type_checking.rs:22:9
100+
|
101+
LL | debug_printf!("%u", 11.0_f32);
102+
| ^^^^^^^^^^^^^^^^^^^^--------^
103+
| |
104+
| this argument influences the return type of `debug_printf_assert_is_type`
105105
note: function defined here
106-
--> $SPIRV_STD_SRC/lib.rs:134:8
107-
|
108-
134 | pub fn debug_printf_assert_is_type<T>(ty: T) -> T {
109-
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
110-
= note: this error originates in the macro `debug_printf` (in Nightly builds, run with -Z macro-backtrace for more info)
106+
--> $SPIRV_STD_SRC/lib.rs:134:8
107+
|
108+
LL | pub fn debug_printf_assert_is_type<T>(ty: T) -> T {
109+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
110+
= note: this error originates in the macro `debug_printf` (in Nightly builds, run with -Z macro-backtrace for more info)
111111
help: change the type of the numeric literal from `f32` to `u32`
112-
|
113-
22 - debug_printf!("%u", 11.0_f32);
114-
22 + debug_printf!("%u", 11u32);
115-
|
112+
|
113+
LL - debug_printf!("%u", 11.0_f32);
114+
LL + debug_printf!("%u", 11u32);
115+
|
116116

117117
error[E0277]: the trait bound `{float}: Vector<f32, 2>` is not satisfied
118-
--> $DIR/debug_printf_type_checking.rs:23:9
119-
|
120-
23 | debug_printf!("%v2f", 11.0);
121-
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `Vector<f32, 2>` is not implemented for `{float}`
122-
|
123-
= help: the following other types implement trait `Vector<T, N>`:
124-
`BVec2` implements `Vector<bool, 2>`
125-
`BVec3` implements `Vector<bool, 3>`
126-
`BVec4` implements `Vector<bool, 4>`
127-
`DVec2` implements `Vector<f64, 2>`
128-
`DVec3` implements `Vector<f64, 3>`
129-
`DVec4` implements `Vector<f64, 4>`
130-
`IVec2` implements `Vector<i32, 2>`
131-
`IVec3` implements `Vector<i32, 3>`
132-
and 8 others
118+
--> $DIR/debug_printf_type_checking.rs:23:9
119+
|
120+
LL | debug_printf!("%v2f", 11.0);
121+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `Vector<f32, 2>` is not implemented for `{float}`
122+
|
123+
= help: the following other types implement trait `Vector<T, N>`:
124+
`BVec2` implements `Vector<bool, 2>`
125+
`BVec3` implements `Vector<bool, 3>`
126+
`BVec4` implements `Vector<bool, 4>`
127+
`DVec2` implements `Vector<f64, 2>`
128+
`DVec3` implements `Vector<f64, 3>`
129+
`DVec4` implements `Vector<f64, 4>`
130+
`IVec2` implements `Vector<i32, 2>`
131+
`IVec3` implements `Vector<i32, 3>`
132+
and 8 others
133133
note: required by a bound in `debug_printf_assert_is_vector`
134-
--> $SPIRV_STD_SRC/lib.rs:141:8
135-
|
136-
139 | pub fn debug_printf_assert_is_vector<
137-
| ----------------------------- required by a bound in this function
138-
140 | TY: crate::scalar::Scalar,
139-
141 | V: crate::vector::Vector<TY, SIZE>,
140-
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `debug_printf_assert_is_vector`
141-
= note: this error originates in the macro `debug_printf` (in Nightly builds, run with -Z macro-backtrace for more info)
134+
--> $SPIRV_STD_SRC/lib.rs:141:8
135+
|
136+
LL | pub fn debug_printf_assert_is_vector<
137+
| ----------------------------- required by a bound in this function
138+
LL | TY: crate::scalar::Scalar,
139+
LL | V: crate::vector::Vector<TY, SIZE>,
140+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `debug_printf_assert_is_vector`
141+
= note: this error originates in the macro `debug_printf` (in Nightly builds, run with -Z macro-backtrace for more info)
142142

143143
error[E0308]: mismatched types
144-
--> $DIR/debug_printf_type_checking.rs:24:29
145-
|
146-
24 | debug_printf!("%f", Vec2::splat(33.3));
147-
| --------------------^^^^^^^^^^^^^^^^^-
148-
| | |
149-
| | expected `f32`, found `Vec2`
150-
| arguments to this function are incorrect
151-
|
144+
--> $DIR/debug_printf_type_checking.rs:24:29
145+
|
146+
LL | debug_printf!("%f", Vec2::splat(33.3));
147+
| --------------------^^^^^^^^^^^^^^^^^-
148+
| | |
149+
| | expected `f32`, found `Vec2`
150+
| arguments to this function are incorrect
151+
|
152152
help: the return type of this call is `Vec2` due to the type of the argument passed
153-
--> $DIR/debug_printf_type_checking.rs:24:9
154-
|
155-
24 | debug_printf!("%f", Vec2::splat(33.3));
156-
| ^^^^^^^^^^^^^^^^^^^^-----------------^
157-
| |
158-
| this argument influences the return type of `debug_printf_assert_is_type`
153+
--> $DIR/debug_printf_type_checking.rs:24:9
154+
|
155+
LL | debug_printf!("%f", Vec2::splat(33.3));
156+
| ^^^^^^^^^^^^^^^^^^^^-----------------^
157+
| |
158+
| this argument influences the return type of `debug_printf_assert_is_type`
159159
note: function defined here
160-
--> $SPIRV_STD_SRC/lib.rs:134:8
161-
|
162-
134 | pub fn debug_printf_assert_is_type<T>(ty: T) -> T {
163-
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
164-
= note: this error originates in the macro `debug_printf` (in Nightly builds, run with -Z macro-backtrace for more info)
160+
--> $SPIRV_STD_SRC/lib.rs:134:8
161+
|
162+
LL | pub fn debug_printf_assert_is_type<T>(ty: T) -> T {
163+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
164+
= note: this error originates in the macro `debug_printf` (in Nightly builds, run with -Z macro-backtrace for more info)
165165

166166
error: aborting due to 14 previous errors
167167

tests/compiletests/ui/arch/subgroup/subgroup_cluster_size_0_fail.stderr

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,35 @@
11
error[E0080]: evaluation panicked: `ClusterSize` must be at least 1
2-
--> $SPIRV_STD_SRC/arch/subgroup.rs:826:1
3-
|
4-
826 | / macro_subgroup_op_clustered!(impl Integer, "OpGroupNonUniformIAdd", subgroup_clustered_i_add; r"
5-
827 | | An integer add group operation of all `value` operands contributed by active invocations in the group.
6-
828 | |
7-
829 | | Result Type must be a scalar or vector of integer type.
8-
... |
9-
842 | | * `ClusterSize` must not be greater than the size of the group
10-
843 | | ");
11-
| |__^ evaluation of `spirv_std::arch::subgroup_clustered_i_add::<0, u32, u32>::{constant#0}` failed here
12-
|
13-
= note: this error originates in the macro `$crate::panic::panic_2021` which comes from the expansion of the macro `macro_subgroup_op_clustered` (in Nightly builds, run with -Z macro-backtrace for more info)
2+
--> $SPIRV_STD_SRC/arch/subgroup.rs:826:1
3+
|
4+
LL | / macro_subgroup_op_clustered!(impl Integer, "OpGroupNonUniformIAdd", subgroup_clustered_i_add; r"
5+
LL | | An integer add group operation of all `value` operands contributed by active invocations in the group.
6+
LL | |
7+
LL | | Result Type must be a scalar or vector of integer type.
8+
... |
9+
LL | | * `ClusterSize` must not be greater than the size of the group
10+
LL | | ");
11+
| |__^ evaluation of `spirv_std::arch::subgroup_clustered_i_add::<0, u32, u32>::{constant#0}` failed here
12+
|
13+
= note: this error originates in the macro `$crate::panic::panic_2021` which comes from the expansion of the macro `macro_subgroup_op_clustered` (in Nightly builds, run with -Z macro-backtrace for more info)
1414

1515
note: erroneous constant encountered
16-
--> $SPIRV_STD_SRC/arch/subgroup.rs:826:1
17-
|
18-
826 | / macro_subgroup_op_clustered!(impl Integer, "OpGroupNonUniformIAdd", subgroup_clustered_i_add; r"
19-
827 | | An integer add group operation of all `value` operands contributed by active invocations in the group.
20-
828 | |
21-
829 | | Result Type must be a scalar or vector of integer type.
22-
... |
23-
842 | | * `ClusterSize` must not be greater than the size of the group
24-
843 | | ");
25-
| |__^
26-
|
27-
= note: this note originates in the macro `macro_subgroup_op_clustered` (in Nightly builds, run with -Z macro-backtrace for more info)
16+
--> $SPIRV_STD_SRC/arch/subgroup.rs:826:1
17+
|
18+
LL | / macro_subgroup_op_clustered!(impl Integer, "OpGroupNonUniformIAdd", subgroup_clustered_i_add; r"
19+
LL | | An integer add group operation of all `value` operands contributed by active invocations in the group.
20+
LL | |
21+
LL | | Result Type must be a scalar or vector of integer type.
22+
... |
23+
LL | | * `ClusterSize` must not be greater than the size of the group
24+
LL | | ");
25+
| |__^
26+
|
27+
= note: this note originates in the macro `macro_subgroup_op_clustered` (in Nightly builds, run with -Z macro-backtrace for more info)
2828

2929
note: the above error was encountered while instantiating `fn spirv_std::arch::subgroup_clustered_i_add::<0, u32, u32>`
3030
--> $DIR/subgroup_cluster_size_0_fail.rs:10:5
3131
|
32-
10 | spirv_std::arch::subgroup_clustered_i_add::<0, _>(value)
32+
LL | spirv_std::arch::subgroup_clustered_i_add::<0, _>(value)
3333
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
3434

3535
error: aborting due to 1 previous error

tests/compiletests/ui/arch/subgroup/subgroup_cluster_size_non_power_of_two_fail.stderr

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,35 @@
11
error[E0080]: evaluation panicked: `ClusterSize` must be a power of 2
2-
--> $SPIRV_STD_SRC/arch/subgroup.rs:826:1
3-
|
4-
826 | / macro_subgroup_op_clustered!(impl Integer, "OpGroupNonUniformIAdd", subgroup_clustered_i_add; r"
5-
827 | | An integer add group operation of all `value` operands contributed by active invocations in the group.
6-
828 | |
7-
829 | | Result Type must be a scalar or vector of integer type.
8-
... |
9-
842 | | * `ClusterSize` must not be greater than the size of the group
10-
843 | | ");
11-
| |__^ evaluation of `spirv_std::arch::subgroup_clustered_i_add::<5, u32, u32>::{constant#0}` failed here
12-
|
13-
= note: this error originates in the macro `$crate::panic::panic_2021` which comes from the expansion of the macro `macro_subgroup_op_clustered` (in Nightly builds, run with -Z macro-backtrace for more info)
2+
--> $SPIRV_STD_SRC/arch/subgroup.rs:826:1
3+
|
4+
LL | / macro_subgroup_op_clustered!(impl Integer, "OpGroupNonUniformIAdd", subgroup_clustered_i_add; r"
5+
LL | | An integer add group operation of all `value` operands contributed by active invocations in the group.
6+
LL | |
7+
LL | | Result Type must be a scalar or vector of integer type.
8+
... |
9+
LL | | * `ClusterSize` must not be greater than the size of the group
10+
LL | | ");
11+
| |__^ evaluation of `spirv_std::arch::subgroup_clustered_i_add::<5, u32, u32>::{constant#0}` failed here
12+
|
13+
= note: this error originates in the macro `$crate::panic::panic_2021` which comes from the expansion of the macro `macro_subgroup_op_clustered` (in Nightly builds, run with -Z macro-backtrace for more info)
1414

1515
note: erroneous constant encountered
16-
--> $SPIRV_STD_SRC/arch/subgroup.rs:826:1
17-
|
18-
826 | / macro_subgroup_op_clustered!(impl Integer, "OpGroupNonUniformIAdd", subgroup_clustered_i_add; r"
19-
827 | | An integer add group operation of all `value` operands contributed by active invocations in the group.
20-
828 | |
21-
829 | | Result Type must be a scalar or vector of integer type.
22-
... |
23-
842 | | * `ClusterSize` must not be greater than the size of the group
24-
843 | | ");
25-
| |__^
26-
|
27-
= note: this note originates in the macro `macro_subgroup_op_clustered` (in Nightly builds, run with -Z macro-backtrace for more info)
16+
--> $SPIRV_STD_SRC/arch/subgroup.rs:826:1
17+
|
18+
LL | / macro_subgroup_op_clustered!(impl Integer, "OpGroupNonUniformIAdd", subgroup_clustered_i_add; r"
19+
LL | | An integer add group operation of all `value` operands contributed by active invocations in the group.
20+
LL | |
21+
LL | | Result Type must be a scalar or vector of integer type.
22+
... |
23+
LL | | * `ClusterSize` must not be greater than the size of the group
24+
LL | | ");
25+
| |__^
26+
|
27+
= note: this note originates in the macro `macro_subgroup_op_clustered` (in Nightly builds, run with -Z macro-backtrace for more info)
2828

2929
note: the above error was encountered while instantiating `fn spirv_std::arch::subgroup_clustered_i_add::<5, u32, u32>`
3030
--> $DIR/subgroup_cluster_size_non_power_of_two_fail.rs:10:5
3131
|
32-
10 | spirv_std::arch::subgroup_clustered_i_add::<5, _>(value)
32+
LL | spirv_std::arch::subgroup_clustered_i_add::<5, _>(value)
3333
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
3434

3535
error: aborting due to 1 previous error

0 commit comments

Comments
 (0)