]> git.proxmox.com Git - rustc.git/blob - tests/ui/test-attrs/test-attr-non-associated-functions.stderr
New upstream version 1.70.0+dfsg1
[rustc.git] / tests / ui / test-attrs / test-attr-non-associated-functions.stderr
1 error: the `#[test]` attribute may only be used on a non-associated function
2 --> $DIR/test-attr-non-associated-functions.rs:6:5
3 |
4 LL | #[test]
5 | ^^^^^^^ the `#[test]` macro causes a function to be run as a test and has no effect on non-functions
6 |
7 help: replace with conditional compilation to make the item only exist when tests are being run
8 |
9 LL | #[cfg(test)]
10 |
11
12 error: the `#[test]` attribute may only be used on a non-associated function
13 --> $DIR/test-attr-non-associated-functions.rs:11:5
14 |
15 LL | #[test]
16 | ^^^^^^^ the `#[test]` macro causes a function to be run as a test and has no effect on non-functions
17 |
18 help: replace with conditional compilation to make the item only exist when tests are being run
19 |
20 LL | #[cfg(test)]
21 |
22
23 error: aborting due to 2 previous errors
24