File tree Expand file tree Collapse file tree 1 file changed +9
-7
lines changed
src/librustc_error_codes/error_codes Expand file tree Collapse file tree 1 file changed +9
-7
lines changed Original file line number Diff line number Diff line change 1- The ` #[simd] ` attribute can only be applied to non empty tuple structs, because
2- it doesn't make sense to try to use SIMD operations when there are no values to
3- operate on.
1+ A ` #[simd] ` attribute was applied to an empty tuple struct.
42
5- This will cause an error :
3+ Erroneous code example :
64
75``` compile_fail,E0075
86#![feature(repr_simd)]
97
108#[repr(simd)]
11- struct Bad;
9+ struct Bad; // error!
1210```
1311
14- This will not:
12+ The ` #[simd] ` attribute can only be applied to non empty tuple structs, because
13+ it doesn't make sense to try to use SIMD operations when there are no values to
14+ operate on.
15+
16+ Fixed example:
1517
1618```
1719#![feature(repr_simd)]
1820
1921#[repr(simd)]
20- struct Good(u32);
22+ struct Good(u32); // ok!
2123```
You can’t perform that action at this time.
0 commit comments