mirror of
https://github.com/allankoechke/rust.git
synced 2026-11-30 11:05:36 +00:00
Mostly in a fashion similar to the previous commit. There is one exceptional case: for errors involving `repr` the argument is significant. For these, the argument is included in the error line and the caret highlighting, e.g. ``` error: the `repr(C)` attribute cannot be used on functions --> $DIR/naked-with-invalid-repr-attr.rs:10:3 | LL | #[repr(C)] | ^^^^^^^ | = help: the `repr(C)` attribute can only be applied to data types ``` Contrast this with a more typical argument-excluding case used everywhere else: ``` error: the `rustc_abi` attribute cannot be used on associated consts --> $DIR/debug.rs:46:7 | LL | #[rustc_abi(debug)] | ^^^^^^^^^ | = help: the `rustc_abi` attribute can be applied to functions and type aliases ```
19 lines
683 B
Plaintext
19 lines
683 B
Plaintext
error: the `export_stable` attribute cannot be used on traits
|
|
--> $DIR/exportable.rs:135:7
|
|
|
|
|
LL | #[export_stable]
|
|
| ^^^^^^^^^^^^^
|
|
|
|
|
= help: the `export_stable` attribute can be applied to associated types, data types, functions, inherent impl blocks, modules, type aliases, and use statements
|
|
|
|
error: the `export_stable` attribute cannot be used on constants
|
|
--> $DIR/exportable.rs:139:7
|
|
|
|
|
LL | #[export_stable]
|
|
| ^^^^^^^^^^^^^
|
|
|
|
|
= help: the `export_stable` attribute can be applied to associated types, data types, functions, inherent impl blocks, modules, type aliases, and use statements
|
|
|
|
error: aborting due to 2 previous errors
|
|
|