2019-12-04 04:16:12 -06:00
|
|
|
error: expected expression, found `]`
|
2023-02-27 07:07:44 -06:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:3:40
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = [#[attr]]; }
|
|
|
|
| ^ expected expression
|
|
|
|
|
2021-08-01 19:55:48 -05:00
|
|
|
error: expected one of `!`, `.`, `::`, `;`, `?`, `else`, `{`, or an operator, found `#`
|
2023-02-27 07:07:44 -06:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:5:35
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = foo#[attr](); }
|
2021-08-01 19:55:48 -05:00
|
|
|
| ^ expected one of 8 possible tokens
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted in this context
|
2023-02-27 07:07:44 -06:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:7:36
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = foo(#![attr]); }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
2022-11-16 14:46:06 -06:00
|
|
|
error: an inner attribute is not permitted in this context
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:7:36
|
2022-11-16 14:46:06 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = foo(#![attr]); }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
|
|
|
|
2019-12-04 04:16:12 -06:00
|
|
|
error: expected expression, found `)`
|
2023-02-27 07:07:44 -06:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:7:44
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = foo(#![attr]); }
|
|
|
|
| ^ expected expression
|
|
|
|
|
|
|
|
error: an inner attribute is not permitted in this context
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:11:38
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = x.foo(#![attr]); }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: expected expression, found `)`
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:11:46
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = x.foo(#![attr]); }
|
|
|
|
| ^ expected expression
|
|
|
|
|
|
|
|
error: an inner attribute is not permitted in this context
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:14:36
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = 0 + #![attr] 0; }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted in this context
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:16:33
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = !#![attr] 0; }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted in this context
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:18:33
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = -#![attr] 0; }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
2021-08-01 19:55:48 -05:00
|
|
|
error: expected one of `!`, `.`, `::`, `;`, `?`, `else`, `{`, or an operator, found `#`
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:20:34
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = x #![attr] as Y; }
|
2021-08-01 19:55:48 -05:00
|
|
|
| ^ expected one of 8 possible tokens
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted in this context
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:22:35
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = || #![attr] foo; }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted in this context
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:24:40
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = move || #![attr] foo; }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted in this context
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:26:35
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = || #![attr] {foo}; }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted in this context
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:28:40
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = move || #![attr] {foo}; }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: expected expression, found `..`
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:30:40
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = #[attr] ..#[attr] 0; }
|
|
|
|
| ^^ expected expression
|
|
|
|
|
|
|
|
error: expected expression, found `..`
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:32:40
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = #[attr] ..; }
|
|
|
|
| ^^ expected expression
|
|
|
|
|
|
|
|
error: an inner attribute is not permitted in this context
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:34:41
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = #[attr] &#![attr] 0; }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted in this context
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:36:45
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = #[attr] &mut #![attr] 0; }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
2020-03-07 10:16:29 -06:00
|
|
|
error: outer attributes are not allowed on `if` and `else` branches
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:38:37
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = if 0 #[attr] {}; }
|
2020-03-07 10:16:29 -06:00
|
|
|
| -- ^^^^^^^ -- the attributes are attached to this branch
|
2019-12-04 04:16:12 -06:00
|
|
|
| | |
|
2020-03-07 10:16:29 -06:00
|
|
|
| | help: remove the attributes
|
|
|
|
| the branch belongs to this `if`
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted in this context
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:40:38
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = if 0 {#![attr]}; }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: expected one of `.`, `;`, `?`, `else`, or an operator, found `#`
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:42:40
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = if 0 {} #[attr] else {}; }
|
|
|
|
| ^ expected one of `.`, `;`, `?`, `else`, or an operator
|
|
|
|
|
2020-03-07 10:16:29 -06:00
|
|
|
error: outer attributes are not allowed on `if` and `else` branches
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:44:45
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = if 0 {} else #[attr] {}; }
|
2020-03-07 10:16:29 -06:00
|
|
|
| ---- ^^^^^^^ -- the attributes are attached to this branch
|
|
|
|
| | |
|
|
|
|
| | help: remove the attributes
|
|
|
|
| the branch belongs to this `else`
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted in this context
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:46:46
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = if 0 {} else {#![attr]}; }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
2020-03-07 10:16:29 -06:00
|
|
|
error: outer attributes are not allowed on `if` and `else` branches
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:48:45
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = if 0 {} else #[attr] if 0 {}; }
|
2020-03-07 10:16:29 -06:00
|
|
|
| ---- ^^^^^^^ ------- the attributes are attached to this branch
|
|
|
|
| | |
|
|
|
|
| | help: remove the attributes
|
|
|
|
| the branch belongs to this `else`
|
2019-12-04 04:16:12 -06:00
|
|
|
|
2020-03-07 10:16:29 -06:00
|
|
|
error: outer attributes are not allowed on `if` and `else` branches
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:50:50
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = if 0 {} else if 0 #[attr] {}; }
|
2020-03-07 10:16:29 -06:00
|
|
|
| -- ^^^^^^^ -- the attributes are attached to this branch
|
2019-12-04 04:16:12 -06:00
|
|
|
| | |
|
2020-03-07 10:16:29 -06:00
|
|
|
| | help: remove the attributes
|
|
|
|
| the branch belongs to this `if`
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted in this context
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:52:51
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = if 0 {} else if 0 {#![attr]}; }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
2020-03-07 10:16:29 -06:00
|
|
|
error: outer attributes are not allowed on `if` and `else` branches
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:54:45
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = if let _ = 0 #[attr] {}; }
|
2020-03-07 10:16:29 -06:00
|
|
|
| -- ^^^^^^^ -- the attributes are attached to this branch
|
2019-12-04 04:16:12 -06:00
|
|
|
| | |
|
2020-03-07 10:16:29 -06:00
|
|
|
| | help: remove the attributes
|
|
|
|
| the branch belongs to this `if`
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted in this context
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:56:46
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = if let _ = 0 {#![attr]}; }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: expected one of `.`, `;`, `?`, `else`, or an operator, found `#`
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:58:48
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = if let _ = 0 {} #[attr] else {}; }
|
|
|
|
| ^ expected one of `.`, `;`, `?`, `else`, or an operator
|
|
|
|
|
2020-03-07 10:16:29 -06:00
|
|
|
error: outer attributes are not allowed on `if` and `else` branches
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:60:53
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = if let _ = 0 {} else #[attr] {}; }
|
2020-03-07 10:16:29 -06:00
|
|
|
| ---- ^^^^^^^ -- the attributes are attached to this branch
|
|
|
|
| | |
|
|
|
|
| | help: remove the attributes
|
|
|
|
| the branch belongs to this `else`
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted in this context
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:62:54
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = if let _ = 0 {} else {#![attr]}; }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
2020-03-07 10:16:29 -06:00
|
|
|
error: outer attributes are not allowed on `if` and `else` branches
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:64:53
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = if let _ = 0 {} else #[attr] if let _ = 0 {}; }
|
2020-03-07 10:16:29 -06:00
|
|
|
| ---- ^^^^^^^ --------------- the attributes are attached to this branch
|
|
|
|
| | |
|
|
|
|
| | help: remove the attributes
|
|
|
|
| the branch belongs to this `else`
|
2019-12-04 04:16:12 -06:00
|
|
|
|
2020-03-07 10:16:29 -06:00
|
|
|
error: outer attributes are not allowed on `if` and `else` branches
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:66:66
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = if let _ = 0 {} else if let _ = 0 #[attr] {}; }
|
2020-03-07 10:16:29 -06:00
|
|
|
| -- ^^^^^^^ -- the attributes are attached to this branch
|
2019-12-04 04:16:12 -06:00
|
|
|
| | |
|
2020-03-07 10:16:29 -06:00
|
|
|
| | help: remove the attributes
|
|
|
|
| the branch belongs to this `if`
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted in this context
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:68:67
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = if let _ = 0 {} else if let _ = 0 {#![attr]}; }
|
|
|
|
| ^^^^^^^^
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted following an outer attribute
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:71:32
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn s() { #[attr] #![attr] let _ = 0; }
|
2020-03-06 09:02:32 -06:00
|
|
|
| ------- ^^^^^^^^ not permitted following an outer attribute
|
2019-12-04 04:16:12 -06:00
|
|
|
| |
|
|
|
|
| previous outer attribute
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted following an outer attribute
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:73:32
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn s() { #[attr] #![attr] 0; }
|
2020-03-06 09:02:32 -06:00
|
|
|
| ------- ^^^^^^^^ not permitted following an outer attribute
|
2019-12-04 04:16:12 -06:00
|
|
|
| |
|
|
|
|
| previous outer attribute
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
= note: outer attributes, like `#[test]`, annotate the item following them
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted following an outer attribute
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:75:32
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn s() { #[attr] #![attr] foo!(); }
|
2021-08-23 05:49:31 -05:00
|
|
|
| ------- ^^^^^^^^ ------- the inner attribute doesn't annotate this item macro invocation
|
|
|
|
| | |
|
|
|
|
| | not permitted following an outer attribute
|
2019-12-04 04:16:12 -06:00
|
|
|
| previous outer attribute
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
help: to annotate the item macro invocation, change the attribute from inner to outer style
|
|
|
|
|
|
|
|
|
LL - #[cfg(FALSE)] fn s() { #[attr] #![attr] foo!(); }
|
|
|
|
LL + #[cfg(FALSE)] fn s() { #[attr] #[attr] foo!(); }
|
2022-06-08 12:34:57 -05:00
|
|
|
|
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted following an outer attribute
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:77:32
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn s() { #[attr] #![attr] foo![]; }
|
2021-08-23 05:49:31 -05:00
|
|
|
| ------- ^^^^^^^^ ------- the inner attribute doesn't annotate this item macro invocation
|
|
|
|
| | |
|
|
|
|
| | not permitted following an outer attribute
|
2019-12-04 04:16:12 -06:00
|
|
|
| previous outer attribute
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
help: to annotate the item macro invocation, change the attribute from inner to outer style
|
|
|
|
|
|
|
|
|
LL - #[cfg(FALSE)] fn s() { #[attr] #![attr] foo![]; }
|
|
|
|
LL + #[cfg(FALSE)] fn s() { #[attr] #[attr] foo![]; }
|
2022-06-08 12:34:57 -05:00
|
|
|
|
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: an inner attribute is not permitted following an outer attribute
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:79:32
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn s() { #[attr] #![attr] foo!{}; }
|
2021-08-23 05:49:31 -05:00
|
|
|
| ------- ^^^^^^^^ ------ the inner attribute doesn't annotate this item macro invocation
|
|
|
|
| | |
|
|
|
|
| | not permitted following an outer attribute
|
2019-12-04 04:16:12 -06:00
|
|
|
| previous outer attribute
|
|
|
|
|
|
2021-08-23 05:49:31 -05:00
|
|
|
= note: inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually found at the beginning of source files
|
|
|
|
help: to annotate the item macro invocation, change the attribute from inner to outer style
|
|
|
|
|
|
|
|
|
LL - #[cfg(FALSE)] fn s() { #[attr] #![attr] foo!{}; }
|
|
|
|
LL + #[cfg(FALSE)] fn s() { #[attr] #[attr] foo!{}; }
|
2022-06-08 12:34:57 -05:00
|
|
|
|
|
2019-12-04 04:16:12 -06:00
|
|
|
|
2019-12-11 03:04:34 -06:00
|
|
|
error[E0586]: inclusive range with no end
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:85:35
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { match 0 { 0..=#[attr] 10 => () } }
|
2020-01-10 23:49:43 -06:00
|
|
|
| ^^^ help: use `..` instead
|
2019-12-11 03:04:34 -06:00
|
|
|
|
|
2020-01-10 23:49:43 -06:00
|
|
|
= note: inclusive ranges must be bounded at the end (`..=b` or `a..=b`)
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: expected one of `=>`, `if`, or `|`, found `#`
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:85:38
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { match 0 { 0..=#[attr] 10 => () } }
|
|
|
|
| ^ expected one of `=>`, `if`, or `|`
|
|
|
|
|
2019-12-11 03:04:34 -06:00
|
|
|
error[E0586]: inclusive range with no end
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:88:35
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { match 0 { 0..=#[attr] -10 => () } }
|
2020-01-10 23:49:43 -06:00
|
|
|
| ^^^ help: use `..` instead
|
2019-12-11 03:04:34 -06:00
|
|
|
|
|
2020-01-10 23:49:43 -06:00
|
|
|
= note: inclusive ranges must be bounded at the end (`..=b` or `a..=b`)
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: expected one of `=>`, `if`, or `|`, found `#`
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:88:38
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { match 0 { 0..=#[attr] -10 => () } }
|
|
|
|
| ^ expected one of `=>`, `if`, or `|`
|
|
|
|
|
|
|
|
error: unexpected token: `#`
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:91:39
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { match 0 { 0..=-#[attr] 10 => () } }
|
|
|
|
| ^
|
|
|
|
|
2019-12-11 03:04:34 -06:00
|
|
|
error[E0586]: inclusive range with no end
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:93:35
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { match 0 { 0..=#[attr] FOO => () } }
|
2020-01-10 23:49:43 -06:00
|
|
|
| ^^^ help: use `..` instead
|
2019-12-11 03:04:34 -06:00
|
|
|
|
|
2020-01-10 23:49:43 -06:00
|
|
|
= note: inclusive ranges must be bounded at the end (`..=b` or `a..=b`)
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
error: expected one of `=>`, `if`, or `|`, found `#`
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:93:38
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { match 0 { 0..=#[attr] FOO => () } }
|
|
|
|
| ^ expected one of `=>`, `if`, or `|`
|
|
|
|
|
2019-12-06 17:59:56 -06:00
|
|
|
error: unexpected token: `#`
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:97:34
|
2019-12-06 17:59:56 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = x.#![attr]foo(); }
|
|
|
|
| ^
|
|
|
|
|
2021-08-01 19:55:48 -05:00
|
|
|
error: expected one of `.`, `;`, `?`, `else`, or an operator, found `#`
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:97:34
|
2019-12-06 17:59:56 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = x.#![attr]foo(); }
|
2021-08-01 19:55:48 -05:00
|
|
|
| ^ expected one of `.`, `;`, `?`, `else`, or an operator
|
2019-12-06 17:59:56 -06:00
|
|
|
|
|
|
|
error: unexpected token: `#`
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:100:34
|
2019-12-06 17:59:56 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = x.#[attr]foo(); }
|
|
|
|
| ^
|
|
|
|
|
2021-08-01 19:55:48 -05:00
|
|
|
error: expected one of `.`, `;`, `?`, `else`, or an operator, found `#`
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:100:34
|
2019-12-06 17:59:56 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { let _ = x.#[attr]foo(); }
|
2021-08-01 19:55:48 -05:00
|
|
|
| ^ expected one of `.`, `;`, `?`, `else`, or an operator
|
2019-12-06 17:59:56 -06:00
|
|
|
|
2019-12-04 04:16:12 -06:00
|
|
|
error: expected statement after outer attribute
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:105:37
|
2019-12-04 04:16:12 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { { fn foo() { #[attr]; } } }
|
2020-02-26 21:10:42 -06:00
|
|
|
| ^^^^^^^
|
2019-12-04 04:16:12 -06:00
|
|
|
|
2019-12-30 08:09:42 -06:00
|
|
|
error: expected statement after outer attribute
|
2023-03-14 11:00:58 -05:00
|
|
|
--> $DIR/attr-stmt-expr-attr-bad.rs:107:37
|
2019-12-30 08:09:42 -06:00
|
|
|
|
|
|
|
|
LL | #[cfg(FALSE)] fn e() { { fn foo() { #[attr] } } }
|
2020-02-26 21:10:42 -06:00
|
|
|
| ^^^^^^^
|
2019-12-30 08:09:42 -06:00
|
|
|
|
2023-03-14 11:00:58 -05:00
|
|
|
error: aborting due to 53 previous errors
|
2019-12-04 04:16:12 -06:00
|
|
|
|
2019-12-11 03:04:34 -06:00
|
|
|
For more information about this error, try `rustc --explain E0586`.
|