error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:27:9
+ --> $DIR/disallowed-positions.rs:29:9
|
LL | if (let 0 = 1) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:31:11
+ --> $DIR/disallowed-positions.rs:33:11
|
LL | if (((let 0 = 1))) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:35:9
+ --> $DIR/disallowed-positions.rs:37:9
|
LL | if (let 0 = 1) && true {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:39:17
+ --> $DIR/disallowed-positions.rs:41:17
|
LL | if true && (let 0 = 1) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:43:9
+ --> $DIR/disallowed-positions.rs:45:9
|
LL | if (let 0 = 1) && (let 0 = 1) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:43:24
+ --> $DIR/disallowed-positions.rs:45:24
|
LL | if (let 0 = 1) && (let 0 = 1) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:49:35
+ --> $DIR/disallowed-positions.rs:51:35
|
LL | if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:49:48
+ --> $DIR/disallowed-positions.rs:51:48
|
LL | if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:49:61
+ --> $DIR/disallowed-positions.rs:51:61
|
LL | if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:59:12
+ --> $DIR/disallowed-positions.rs:61:12
|
LL | while (let 0 = 1) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:63:14
+ --> $DIR/disallowed-positions.rs:65:14
|
LL | while (((let 0 = 1))) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:67:12
+ --> $DIR/disallowed-positions.rs:69:12
|
LL | while (let 0 = 1) && true {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:71:20
+ --> $DIR/disallowed-positions.rs:73:20
|
LL | while true && (let 0 = 1) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:75:12
+ --> $DIR/disallowed-positions.rs:77:12
|
LL | while (let 0 = 1) && (let 0 = 1) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:75:27
+ --> $DIR/disallowed-positions.rs:77:27
|
LL | while (let 0 = 1) && (let 0 = 1) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:81:38
+ --> $DIR/disallowed-positions.rs:83:38
|
LL | while let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:81:51
+ --> $DIR/disallowed-positions.rs:83:51
|
LL | while let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:81:64
+ --> $DIR/disallowed-positions.rs:83:64
|
LL | while let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:114:9
+ --> $DIR/disallowed-positions.rs:110:9
|
LL | if &let 0 = 0 {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:119:9
+ --> $DIR/disallowed-positions.rs:115:9
|
LL | if !let 0 = 0 {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:122:9
+ --> $DIR/disallowed-positions.rs:118:9
|
LL | if *let 0 = 0 {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:126:9
+ --> $DIR/disallowed-positions.rs:122:9
|
LL | if -let 0 = 0 {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:136:9
+ --> $DIR/disallowed-positions.rs:132:9
|
LL | if (let 0 = 0)? {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:142:16
+ --> $DIR/disallowed-positions.rs:138:16
|
LL | if true || let 0 = 0 {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:145:17
+ --> $DIR/disallowed-positions.rs:141:17
|
LL | if (true || let 0 = 0) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:148:25
+ --> $DIR/disallowed-positions.rs:144:25
|
LL | if true && (true || let 0 = 0) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:151:25
+ --> $DIR/disallowed-positions.rs:147:25
|
LL | if true || (true && let 0 = 0) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:156:12
+ --> $DIR/disallowed-positions.rs:152:12
|
LL | if x = let 0 = 0 {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:161:15
+ --> $DIR/disallowed-positions.rs:157:15
|
LL | if true..(let 0 = 0) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:165:11
+ --> $DIR/disallowed-positions.rs:161:11
|
LL | if ..(let 0 = 0) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:169:9
+ --> $DIR/disallowed-positions.rs:165:9
|
LL | if (let 0 = 0).. {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:200:19
+ --> $DIR/disallowed-positions.rs:196:19
|
LL | if let true = let true = true {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:206:12
+ --> $DIR/disallowed-positions.rs:202:12
|
LL | while &let 0 = 0 {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:211:12
+ --> $DIR/disallowed-positions.rs:207:12
|
LL | while !let 0 = 0 {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:214:12
+ --> $DIR/disallowed-positions.rs:210:12
|
LL | while *let 0 = 0 {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:218:12
+ --> $DIR/disallowed-positions.rs:214:12
|
LL | while -let 0 = 0 {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:228:12
+ --> $DIR/disallowed-positions.rs:224:12
|
LL | while (let 0 = 0)? {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:234:19
+ --> $DIR/disallowed-positions.rs:230:19
|
LL | while true || let 0 = 0 {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:237:20
+ --> $DIR/disallowed-positions.rs:233:20
|
LL | while (true || let 0 = 0) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:240:28
+ --> $DIR/disallowed-positions.rs:236:28
|
LL | while true && (true || let 0 = 0) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:243:28
+ --> $DIR/disallowed-positions.rs:239:28
|
LL | while true || (true && let 0 = 0) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:248:15
+ --> $DIR/disallowed-positions.rs:244:15
|
LL | while x = let 0 = 0 {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:253:18
+ --> $DIR/disallowed-positions.rs:249:18
|
LL | while true..(let 0 = 0) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:257:14
+ --> $DIR/disallowed-positions.rs:253:14
|
LL | while ..(let 0 = 0) {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:261:12
+ --> $DIR/disallowed-positions.rs:257:12
|
LL | while (let 0 = 0).. {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:292:22
+ --> $DIR/disallowed-positions.rs:288:22
|
LL | while let true = let true = true {}
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:308:6
+ --> $DIR/disallowed-positions.rs:304:6
|
LL | &let 0 = 0;
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:312:6
+ --> $DIR/disallowed-positions.rs:308:6
|
LL | !let 0 = 0;
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:315:6
+ --> $DIR/disallowed-positions.rs:311:6
|
LL | *let 0 = 0;
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:319:6
+ --> $DIR/disallowed-positions.rs:315:6
|
LL | -let 0 = 0;
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:329:6
+ --> $DIR/disallowed-positions.rs:325:6
|
LL | (let 0 = 0)?;
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:335:13
+ --> $DIR/disallowed-positions.rs:331:13
|
LL | true || let 0 = 0;
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:338:14
+ --> $DIR/disallowed-positions.rs:334:14
|
LL | (true || let 0 = 0);
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:341:22
+ --> $DIR/disallowed-positions.rs:337:22
|
LL | true && (true || let 0 = 0);
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:346:9
+ --> $DIR/disallowed-positions.rs:342:9
|
LL | x = let 0 = 0;
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:350:12
+ --> $DIR/disallowed-positions.rs:346:12
|
LL | true..(let 0 = 0);
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:353:8
+ --> $DIR/disallowed-positions.rs:349:8
|
LL | ..(let 0 = 0);
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:356:6
+ --> $DIR/disallowed-positions.rs:352:6
|
LL | (let 0 = 0)..;
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:360:6
+ --> $DIR/disallowed-positions.rs:356:6
|
LL | (let Range { start: _, end: _ } = true..true || false);
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:365:6
+ --> $DIR/disallowed-positions.rs:361:6
|
LL | (let true = let true = true);
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:365:17
+ --> $DIR/disallowed-positions.rs:361:17
|
LL | (let true = let true = true);
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:372:25
+ --> $DIR/disallowed-positions.rs:368:25
|
LL | let x = true && let y = 1;
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:378:19
+ --> $DIR/disallowed-positions.rs:374:19
|
LL | [1, 2, 3][let _ = ()]
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:383:6
+ --> $DIR/disallowed-positions.rs:379:6
|
LL | &let 0 = 0
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:395:17
+ --> $DIR/disallowed-positions.rs:391:17
|
LL | true && let 1 = 1
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:401:17
+ --> $DIR/disallowed-positions.rs:397:17
|
LL | true && let 1 = 1
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:407:17
+ --> $DIR/disallowed-positions.rs:403:17
|
LL | true && let 1 = 1
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:419:17
+ --> $DIR/disallowed-positions.rs:415:17
|
LL | true && let 1 = 1
| ^^^
error: expressions must be enclosed in braces to be used as const generic arguments
- --> $DIR/disallowed-positions.rs:419:9
+ --> $DIR/disallowed-positions.rs:415:9
|
LL | true && let 1 = 1
| ^^^^^^^^^^^^^^^^^
| + +
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:429:9
+ --> $DIR/disallowed-positions.rs:425:9
|
LL | if (let Some(a) = opt && true) {
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:434:9
+ --> $DIR/disallowed-positions.rs:430:9
|
LL | if (let Some(a) = opt) && true {
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:438:9
+ --> $DIR/disallowed-positions.rs:434:9
|
LL | if (let Some(a) = opt) && (let Some(b) = a) {
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:438:32
+ --> $DIR/disallowed-positions.rs:434:32
|
LL | if (let Some(a) = opt) && (let Some(b) = a) {
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:447:9
+ --> $DIR/disallowed-positions.rs:443:9
|
LL | if (let Some(a) = opt && (let Some(b) = a)) && b == 1 {
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:447:31
+ --> $DIR/disallowed-positions.rs:443:31
|
LL | if (let Some(a) = opt && (let Some(b) = a)) && b == 1 {
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:453:9
+ --> $DIR/disallowed-positions.rs:449:9
|
LL | if (let Some(a) = opt && (let Some(b) = a)) && true {
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:453:31
+ --> $DIR/disallowed-positions.rs:449:31
|
LL | if (let Some(a) = opt && (let Some(b) = a)) && true {
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:459:9
+ --> $DIR/disallowed-positions.rs:455:9
|
LL | if (let Some(a) = opt && (true)) && true {
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:476:22
+ --> $DIR/disallowed-positions.rs:472:22
|
LL | let x = (true && let y = 1);
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:481:20
+ --> $DIR/disallowed-positions.rs:477:20
|
LL | ([1, 2, 3][let _ = ()])
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:485:20
- |
-LL | #[cfg(FALSE)] (let 0 = 1);
- | ^^^
-
-error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:97:16
+ --> $DIR/disallowed-positions.rs:99:16
|
LL | use_expr!((let 0 = 1 && 0 == 0));
| ^^^
error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:101:16
+ --> $DIR/disallowed-positions.rs:103:16
|
LL | use_expr!((let 0 = 1));
| ^^^
-error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:105:23
- |
-LL | use_expr!(true && let 0 = 1);
- | ^^^
-
-error: expected expression, found `let` statement
- --> $DIR/disallowed-positions.rs:109:17
- |
-LL | noop_expr!((let 0 = 1));
- | ^^^
-
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:27:9
+ --> $DIR/disallowed-positions.rs:29:9
|
LL | if (let 0 = 1) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:27:9
+ --> $DIR/disallowed-positions.rs:29:9
|
LL | if (let 0 = 1) {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:31:11
+ --> $DIR/disallowed-positions.rs:33:11
|
LL | if (((let 0 = 1))) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:31:11
+ --> $DIR/disallowed-positions.rs:33:11
|
LL | if (((let 0 = 1))) {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:35:9
+ --> $DIR/disallowed-positions.rs:37:9
|
LL | if (let 0 = 1) && true {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:35:9
+ --> $DIR/disallowed-positions.rs:37:9
|
LL | if (let 0 = 1) && true {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:39:17
+ --> $DIR/disallowed-positions.rs:41:17
|
LL | if true && (let 0 = 1) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:39:17
+ --> $DIR/disallowed-positions.rs:41:17
|
LL | if true && (let 0 = 1) {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:43:9
+ --> $DIR/disallowed-positions.rs:45:9
|
LL | if (let 0 = 1) && (let 0 = 1) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:43:9
+ --> $DIR/disallowed-positions.rs:45:9
|
LL | if (let 0 = 1) && (let 0 = 1) {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:43:24
+ --> $DIR/disallowed-positions.rs:45:24
|
LL | if (let 0 = 1) && (let 0 = 1) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:43:24
+ --> $DIR/disallowed-positions.rs:45:24
|
LL | if (let 0 = 1) && (let 0 = 1) {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:49:35
+ --> $DIR/disallowed-positions.rs:51:35
|
LL | if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:49:35
+ --> $DIR/disallowed-positions.rs:51:35
|
LL | if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:49:48
+ --> $DIR/disallowed-positions.rs:51:48
|
LL | if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:49:35
+ --> $DIR/disallowed-positions.rs:51:35
|
LL | if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:49:61
+ --> $DIR/disallowed-positions.rs:51:61
|
LL | if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:49:35
+ --> $DIR/disallowed-positions.rs:51:35
|
LL | if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:59:12
+ --> $DIR/disallowed-positions.rs:61:12
|
LL | while (let 0 = 1) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:59:12
+ --> $DIR/disallowed-positions.rs:61:12
|
LL | while (let 0 = 1) {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:63:14
+ --> $DIR/disallowed-positions.rs:65:14
|
LL | while (((let 0 = 1))) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:63:14
+ --> $DIR/disallowed-positions.rs:65:14
|
LL | while (((let 0 = 1))) {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:67:12
+ --> $DIR/disallowed-positions.rs:69:12
|
LL | while (let 0 = 1) && true {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:67:12
+ --> $DIR/disallowed-positions.rs:69:12
|
LL | while (let 0 = 1) && true {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:71:20
+ --> $DIR/disallowed-positions.rs:73:20
|
LL | while true && (let 0 = 1) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:71:20
+ --> $DIR/disallowed-positions.rs:73:20
|
LL | while true && (let 0 = 1) {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:75:12
+ --> $DIR/disallowed-positions.rs:77:12
|
LL | while (let 0 = 1) && (let 0 = 1) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:75:12
+ --> $DIR/disallowed-positions.rs:77:12
|
LL | while (let 0 = 1) && (let 0 = 1) {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:75:27
+ --> $DIR/disallowed-positions.rs:77:27
|
LL | while (let 0 = 1) && (let 0 = 1) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:75:27
+ --> $DIR/disallowed-positions.rs:77:27
|
LL | while (let 0 = 1) && (let 0 = 1) {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:81:38
+ --> $DIR/disallowed-positions.rs:83:38
|
LL | while let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:81:38
+ --> $DIR/disallowed-positions.rs:83:38
|
LL | while let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:81:51
+ --> $DIR/disallowed-positions.rs:83:51
|
LL | while let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:81:38
+ --> $DIR/disallowed-positions.rs:83:38
|
LL | while let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:81:64
+ --> $DIR/disallowed-positions.rs:83:64
|
LL | while let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:81:38
+ --> $DIR/disallowed-positions.rs:83:38
|
LL | while let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:97:16
+ --> $DIR/disallowed-positions.rs:99:16
|
LL | use_expr!((let 0 = 1 && 0 == 0));
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:97:16
+ --> $DIR/disallowed-positions.rs:99:16
|
LL | use_expr!((let 0 = 1 && 0 == 0));
| ^^^^^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:97:16
+ --> $DIR/disallowed-positions.rs:99:16
|
LL | use_expr!((let 0 = 1 && 0 == 0));
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:97:16
+ --> $DIR/disallowed-positions.rs:99:16
|
LL | use_expr!((let 0 = 1 && 0 == 0));
| ^^^^^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:101:16
+ --> $DIR/disallowed-positions.rs:103:16
|
LL | use_expr!((let 0 = 1));
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:101:16
+ --> $DIR/disallowed-positions.rs:103:16
|
LL | use_expr!((let 0 = 1));
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:101:16
+ --> $DIR/disallowed-positions.rs:103:16
|
LL | use_expr!((let 0 = 1));
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:101:16
+ --> $DIR/disallowed-positions.rs:103:16
|
LL | use_expr!((let 0 = 1));
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:114:9
+ --> $DIR/disallowed-positions.rs:110:9
|
LL | if &let 0 = 0 {}
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:119:9
+ --> $DIR/disallowed-positions.rs:115:9
|
LL | if !let 0 = 0 {}
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:122:9
+ --> $DIR/disallowed-positions.rs:118:9
|
LL | if *let 0 = 0 {}
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:126:9
+ --> $DIR/disallowed-positions.rs:122:9
|
LL | if -let 0 = 0 {}
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:136:9
+ --> $DIR/disallowed-positions.rs:132:9
|
LL | if (let 0 = 0)? {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:136:9
+ --> $DIR/disallowed-positions.rs:132:9
|
LL | if (let 0 = 0)? {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:142:16
+ --> $DIR/disallowed-positions.rs:138:16
|
LL | if true || let 0 = 0 {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `||` operators are not supported in let chain expressions
- --> $DIR/disallowed-positions.rs:142:13
+ --> $DIR/disallowed-positions.rs:138:13
|
LL | if true || let 0 = 0 {}
| ^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:145:17
+ --> $DIR/disallowed-positions.rs:141:17
|
LL | if (true || let 0 = 0) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `||` operators are not supported in let chain expressions
- --> $DIR/disallowed-positions.rs:145:14
+ --> $DIR/disallowed-positions.rs:141:14
|
LL | if (true || let 0 = 0) {}
| ^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:148:25
+ --> $DIR/disallowed-positions.rs:144:25
|
LL | if true && (true || let 0 = 0) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `||` operators are not supported in let chain expressions
- --> $DIR/disallowed-positions.rs:148:22
+ --> $DIR/disallowed-positions.rs:144:22
|
LL | if true && (true || let 0 = 0) {}
| ^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:151:25
+ --> $DIR/disallowed-positions.rs:147:25
|
LL | if true || (true && let 0 = 0) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:151:17
+ --> $DIR/disallowed-positions.rs:147:17
|
LL | if true || (true && let 0 = 0) {}
| ^^^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:156:12
+ --> $DIR/disallowed-positions.rs:152:12
|
LL | if x = let 0 = 0 {}
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:161:15
+ --> $DIR/disallowed-positions.rs:157:15
|
LL | if true..(let 0 = 0) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:161:15
+ --> $DIR/disallowed-positions.rs:157:15
|
LL | if true..(let 0 = 0) {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:165:11
+ --> $DIR/disallowed-positions.rs:161:11
|
LL | if ..(let 0 = 0) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:165:11
+ --> $DIR/disallowed-positions.rs:161:11
|
LL | if ..(let 0 = 0) {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:169:9
+ --> $DIR/disallowed-positions.rs:165:9
|
LL | if (let 0 = 0).. {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:169:9
+ --> $DIR/disallowed-positions.rs:165:9
|
LL | if (let 0 = 0).. {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:175:8
+ --> $DIR/disallowed-positions.rs:171:8
|
LL | if let Range { start: _, end: _ } = true..true && false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:179:8
+ --> $DIR/disallowed-positions.rs:175:8
|
LL | if let Range { start: _, end: _ } = true..true || false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:186:8
+ --> $DIR/disallowed-positions.rs:182:8
|
LL | if let Range { start: F, end } = F..|| true {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:194:8
+ --> $DIR/disallowed-positions.rs:190:8
|
LL | if let Range { start: true, end } = t..&&false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:200:19
+ --> $DIR/disallowed-positions.rs:196:19
|
LL | if let true = let true = true {}
| ^^^^^^^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:206:12
+ --> $DIR/disallowed-positions.rs:202:12
|
LL | while &let 0 = 0 {}
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:211:12
+ --> $DIR/disallowed-positions.rs:207:12
|
LL | while !let 0 = 0 {}
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:214:12
+ --> $DIR/disallowed-positions.rs:210:12
|
LL | while *let 0 = 0 {}
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:218:12
+ --> $DIR/disallowed-positions.rs:214:12
|
LL | while -let 0 = 0 {}
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:228:12
+ --> $DIR/disallowed-positions.rs:224:12
|
LL | while (let 0 = 0)? {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:228:12
+ --> $DIR/disallowed-positions.rs:224:12
|
LL | while (let 0 = 0)? {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:234:19
+ --> $DIR/disallowed-positions.rs:230:19
|
LL | while true || let 0 = 0 {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `||` operators are not supported in let chain expressions
- --> $DIR/disallowed-positions.rs:234:16
+ --> $DIR/disallowed-positions.rs:230:16
|
LL | while true || let 0 = 0 {}
| ^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:237:20
+ --> $DIR/disallowed-positions.rs:233:20
|
LL | while (true || let 0 = 0) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `||` operators are not supported in let chain expressions
- --> $DIR/disallowed-positions.rs:237:17
+ --> $DIR/disallowed-positions.rs:233:17
|
LL | while (true || let 0 = 0) {}
| ^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:240:28
+ --> $DIR/disallowed-positions.rs:236:28
|
LL | while true && (true || let 0 = 0) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `||` operators are not supported in let chain expressions
- --> $DIR/disallowed-positions.rs:240:25
+ --> $DIR/disallowed-positions.rs:236:25
|
LL | while true && (true || let 0 = 0) {}
| ^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:243:28
+ --> $DIR/disallowed-positions.rs:239:28
|
LL | while true || (true && let 0 = 0) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:243:20
+ --> $DIR/disallowed-positions.rs:239:20
|
LL | while true || (true && let 0 = 0) {}
| ^^^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:248:15
+ --> $DIR/disallowed-positions.rs:244:15
|
LL | while x = let 0 = 0 {}
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:253:18
+ --> $DIR/disallowed-positions.rs:249:18
|
LL | while true..(let 0 = 0) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:253:18
+ --> $DIR/disallowed-positions.rs:249:18
|
LL | while true..(let 0 = 0) {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:257:14
+ --> $DIR/disallowed-positions.rs:253:14
|
LL | while ..(let 0 = 0) {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:257:14
+ --> $DIR/disallowed-positions.rs:253:14
|
LL | while ..(let 0 = 0) {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:261:12
+ --> $DIR/disallowed-positions.rs:257:12
|
LL | while (let 0 = 0).. {}
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:261:12
+ --> $DIR/disallowed-positions.rs:257:12
|
LL | while (let 0 = 0).. {}
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:267:11
+ --> $DIR/disallowed-positions.rs:263:11
|
LL | while let Range { start: _, end: _ } = true..true && false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:271:11
+ --> $DIR/disallowed-positions.rs:267:11
|
LL | while let Range { start: _, end: _ } = true..true || false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:278:11
+ --> $DIR/disallowed-positions.rs:274:11
|
LL | while let Range { start: F, end } = F..|| true {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:286:11
+ --> $DIR/disallowed-positions.rs:282:11
|
LL | while let Range { start: true, end } = t..&&false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:292:22
+ --> $DIR/disallowed-positions.rs:288:22
|
LL | while let true = let true = true {}
| ^^^^^^^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:308:6
+ --> $DIR/disallowed-positions.rs:304:6
|
LL | &let 0 = 0;
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:312:6
+ --> $DIR/disallowed-positions.rs:308:6
|
LL | !let 0 = 0;
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:315:6
+ --> $DIR/disallowed-positions.rs:311:6
|
LL | *let 0 = 0;
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:319:6
+ --> $DIR/disallowed-positions.rs:315:6
|
LL | -let 0 = 0;
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:329:6
+ --> $DIR/disallowed-positions.rs:325:6
|
LL | (let 0 = 0)?;
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:329:6
+ --> $DIR/disallowed-positions.rs:325:6
|
LL | (let 0 = 0)?;
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:335:13
+ --> $DIR/disallowed-positions.rs:331:13
|
LL | true || let 0 = 0;
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `||` operators are not supported in let chain expressions
- --> $DIR/disallowed-positions.rs:335:10
+ --> $DIR/disallowed-positions.rs:331:10
|
LL | true || let 0 = 0;
| ^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:338:14
+ --> $DIR/disallowed-positions.rs:334:14
|
LL | (true || let 0 = 0);
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `||` operators are not supported in let chain expressions
- --> $DIR/disallowed-positions.rs:338:11
+ --> $DIR/disallowed-positions.rs:334:11
|
LL | (true || let 0 = 0);
| ^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:341:22
+ --> $DIR/disallowed-positions.rs:337:22
|
LL | true && (true || let 0 = 0);
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `||` operators are not supported in let chain expressions
- --> $DIR/disallowed-positions.rs:341:19
+ --> $DIR/disallowed-positions.rs:337:19
|
LL | true && (true || let 0 = 0);
| ^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:346:9
+ --> $DIR/disallowed-positions.rs:342:9
|
LL | x = let 0 = 0;
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:350:12
+ --> $DIR/disallowed-positions.rs:346:12
|
LL | true..(let 0 = 0);
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:350:12
+ --> $DIR/disallowed-positions.rs:346:12
|
LL | true..(let 0 = 0);
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:353:8
+ --> $DIR/disallowed-positions.rs:349:8
|
LL | ..(let 0 = 0);
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:353:8
+ --> $DIR/disallowed-positions.rs:349:8
|
LL | ..(let 0 = 0);
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:356:6
+ --> $DIR/disallowed-positions.rs:352:6
|
LL | (let 0 = 0)..;
| ^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:356:6
+ --> $DIR/disallowed-positions.rs:352:6
|
LL | (let 0 = 0)..;
| ^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:360:6
+ --> $DIR/disallowed-positions.rs:356:6
|
LL | (let Range { start: _, end: _ } = true..true || false);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:365:6
+ --> $DIR/disallowed-positions.rs:361:6
|
LL | (let true = let true = true);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:365:6
+ --> $DIR/disallowed-positions.rs:361:6
|
LL | (let true = let true = true);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:383:6
+ --> $DIR/disallowed-positions.rs:379:6
|
LL | &let 0 = 0
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:395:17
+ --> $DIR/disallowed-positions.rs:391:17
|
LL | true && let 1 = 1
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:401:17
+ --> $DIR/disallowed-positions.rs:397:17
|
LL | true && let 1 = 1
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:407:17
+ --> $DIR/disallowed-positions.rs:403:17
|
LL | true && let 1 = 1
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:419:17
+ --> $DIR/disallowed-positions.rs:415:17
|
LL | true && let 1 = 1
| ^^^^^^^^^
= note: only supported directly in conditions of `if` and `while` expressions
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:429:9
+ --> $DIR/disallowed-positions.rs:425:9
|
LL | if (let Some(a) = opt && true) {
| ^^^^^^^^^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:429:9
+ --> $DIR/disallowed-positions.rs:425:9
|
LL | if (let Some(a) = opt && true) {
| ^^^^^^^^^^^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:434:9
+ --> $DIR/disallowed-positions.rs:430:9
|
LL | if (let Some(a) = opt) && true {
| ^^^^^^^^^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:434:9
+ --> $DIR/disallowed-positions.rs:430:9
|
LL | if (let Some(a) = opt) && true {
| ^^^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:438:9
+ --> $DIR/disallowed-positions.rs:434:9
|
LL | if (let Some(a) = opt) && (let Some(b) = a) {
| ^^^^^^^^^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:438:9
+ --> $DIR/disallowed-positions.rs:434:9
|
LL | if (let Some(a) = opt) && (let Some(b) = a) {
| ^^^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:438:32
+ --> $DIR/disallowed-positions.rs:434:32
|
LL | if (let Some(a) = opt) && (let Some(b) = a) {
| ^^^^^^^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:438:32
+ --> $DIR/disallowed-positions.rs:434:32
|
LL | if (let Some(a) = opt) && (let Some(b) = a) {
| ^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:447:9
+ --> $DIR/disallowed-positions.rs:443:9
|
LL | if (let Some(a) = opt && (let Some(b) = a)) && b == 1 {
| ^^^^^^^^^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:447:9
+ --> $DIR/disallowed-positions.rs:443:9
|
LL | if (let Some(a) = opt && (let Some(b) = a)) && b == 1 {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:447:31
+ --> $DIR/disallowed-positions.rs:443:31
|
LL | if (let Some(a) = opt && (let Some(b) = a)) && b == 1 {
| ^^^^^^^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:447:31
+ --> $DIR/disallowed-positions.rs:443:31
|
LL | if (let Some(a) = opt && (let Some(b) = a)) && b == 1 {
| ^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:453:9
+ --> $DIR/disallowed-positions.rs:449:9
|
LL | if (let Some(a) = opt && (let Some(b) = a)) && true {
| ^^^^^^^^^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:453:9
+ --> $DIR/disallowed-positions.rs:449:9
|
LL | if (let Some(a) = opt && (let Some(b) = a)) && true {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:453:31
+ --> $DIR/disallowed-positions.rs:449:31
|
LL | if (let Some(a) = opt && (let Some(b) = a)) && true {
| ^^^^^^^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:453:31
+ --> $DIR/disallowed-positions.rs:449:31
|
LL | if (let Some(a) = opt && (let Some(b) = a)) && true {
| ^^^^^^^^^^^^^^^
error: `let` expressions are not supported here
- --> $DIR/disallowed-positions.rs:459:9
+ --> $DIR/disallowed-positions.rs:455:9
|
LL | if (let Some(a) = opt && (true)) && true {
| ^^^^^^^^^^^^^^^^^
|
= note: only supported directly in conditions of `if` and `while` expressions
note: `let`s wrapped in parentheses are not supported in a context with let chains
- --> $DIR/disallowed-positions.rs:459:9
+ --> $DIR/disallowed-positions.rs:455:9
|
LL | if (let Some(a) = opt && (true)) && true {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:114:8
+ --> $DIR/disallowed-positions.rs:110:8
|
LL | if &let 0 = 0 {}
| ^^^^^^^^^^ expected `bool`, found `&bool`
|
error[E0614]: type `bool` cannot be dereferenced
- --> $DIR/disallowed-positions.rs:122:8
+ --> $DIR/disallowed-positions.rs:118:8
|
LL | if *let 0 = 0 {}
| ^^^^^^^^^^
error[E0600]: cannot apply unary operator `-` to type `bool`
- --> $DIR/disallowed-positions.rs:126:8
+ --> $DIR/disallowed-positions.rs:122:8
|
LL | if -let 0 = 0 {}
| ^^^^^^^^^^ cannot apply unary operator `-`
error[E0277]: the `?` operator can only be applied to values that implement `Try`
- --> $DIR/disallowed-positions.rs:136:8
+ --> $DIR/disallowed-positions.rs:132:8
|
LL | if (let 0 = 0)? {}
| ^^^^^^^^^^^^ the `?` operator cannot be applied to type `bool`
= help: the trait `Try` is not implemented for `bool`
error[E0277]: the `?` operator can only be used in a function that returns `Result` or `Option` (or another type that implements `FromResidual`)
- --> $DIR/disallowed-positions.rs:136:19
+ --> $DIR/disallowed-positions.rs:132:19
|
LL | / fn nested_within_if_expr() {
LL | | if &let 0 = 0 {}
= help: the trait `FromResidual<_>` is not implemented for `()`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:156:8
+ --> $DIR/disallowed-positions.rs:152:8
|
LL | if x = let 0 = 0 {}
| ^^^^^^^^^^^^^ expected `bool`, found `()`
| ~~
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:161:8
+ --> $DIR/disallowed-positions.rs:157:8
|
LL | if true..(let 0 = 0) {}
| ^^^^^^^^^^^^^^^^^ expected `bool`, found struct `std::ops::Range`
found struct `std::ops::Range<bool>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:165:8
+ --> $DIR/disallowed-positions.rs:161:8
|
LL | if ..(let 0 = 0) {}
| ^^^^^^^^^^^^^ expected `bool`, found struct `RangeTo`
found struct `RangeTo<bool>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:169:8
+ --> $DIR/disallowed-positions.rs:165:8
|
LL | if (let 0 = 0).. {}
| ^^^^^^^^^^^^^ expected `bool`, found struct `RangeFrom`
found struct `RangeFrom<bool>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:175:12
+ --> $DIR/disallowed-positions.rs:171:12
|
LL | if let Range { start: _, end: _ } = true..true && false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^ ---- this expression has type `bool`
found struct `std::ops::Range<_>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:175:8
+ --> $DIR/disallowed-positions.rs:171:8
|
LL | if let Range { start: _, end: _ } = true..true && false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found struct `std::ops::Range`
found struct `std::ops::Range<bool>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:179:12
+ --> $DIR/disallowed-positions.rs:175:12
|
LL | if let Range { start: _, end: _ } = true..true || false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^ ---- this expression has type `bool`
found struct `std::ops::Range<_>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:179:8
+ --> $DIR/disallowed-positions.rs:175:8
|
LL | if let Range { start: _, end: _ } = true..true || false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found struct `std::ops::Range`
found struct `std::ops::Range<bool>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:186:12
+ --> $DIR/disallowed-positions.rs:182:12
|
LL | if let Range { start: F, end } = F..|| true {}
| ^^^^^^^^^^^^^^^^^^^^^^^ - this expression has type `fn() -> bool`
found struct `std::ops::Range<_>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:186:41
+ --> $DIR/disallowed-positions.rs:182:41
|
LL | if let Range { start: F, end } = F..|| true {}
| ^^^^^^^ expected `bool`, found closure
|
= note: expected type `bool`
- found closure `[closure@$DIR/disallowed-positions.rs:186:41: 186:43]`
+ found closure `[closure@$DIR/disallowed-positions.rs:182:41: 182:43]`
help: use parentheses to call this closure
|
LL | if let Range { start: F, end } = F..(|| true)() {}
| + +++
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:186:8
+ --> $DIR/disallowed-positions.rs:182:8
|
LL | if let Range { start: F, end } = F..|| true {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found struct `std::ops::Range`
found struct `std::ops::Range<bool>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:194:12
+ --> $DIR/disallowed-positions.rs:190:12
|
LL | if let Range { start: true, end } = t..&&false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^ - this expression has type `&&bool`
found struct `std::ops::Range<_>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:194:44
+ --> $DIR/disallowed-positions.rs:190:44
|
LL | if let Range { start: true, end } = t..&&false {}
| ^^^^^^^ expected `bool`, found `&&bool`
|
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:194:8
+ --> $DIR/disallowed-positions.rs:190:8
|
LL | if let Range { start: true, end } = t..&&false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found struct `std::ops::Range`
found struct `std::ops::Range<bool>`
error[E0277]: the `?` operator can only be applied to values that implement `Try`
- --> $DIR/disallowed-positions.rs:132:20
+ --> $DIR/disallowed-positions.rs:128:20
|
LL | if let 0 = 0? {}
| ^^ the `?` operator cannot be applied to type `{integer}`
= help: the trait `Try` is not implemented for `{integer}`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:206:11
+ --> $DIR/disallowed-positions.rs:202:11
|
LL | while &let 0 = 0 {}
| ^^^^^^^^^^ expected `bool`, found `&bool`
|
error[E0614]: type `bool` cannot be dereferenced
- --> $DIR/disallowed-positions.rs:214:11
+ --> $DIR/disallowed-positions.rs:210:11
|
LL | while *let 0 = 0 {}
| ^^^^^^^^^^
error[E0600]: cannot apply unary operator `-` to type `bool`
- --> $DIR/disallowed-positions.rs:218:11
+ --> $DIR/disallowed-positions.rs:214:11
|
LL | while -let 0 = 0 {}
| ^^^^^^^^^^ cannot apply unary operator `-`
error[E0277]: the `?` operator can only be applied to values that implement `Try`
- --> $DIR/disallowed-positions.rs:228:11
+ --> $DIR/disallowed-positions.rs:224:11
|
LL | while (let 0 = 0)? {}
| ^^^^^^^^^^^^ the `?` operator cannot be applied to type `bool`
= help: the trait `Try` is not implemented for `bool`
error[E0277]: the `?` operator can only be used in a function that returns `Result` or `Option` (or another type that implements `FromResidual`)
- --> $DIR/disallowed-positions.rs:228:22
+ --> $DIR/disallowed-positions.rs:224:22
|
LL | / fn nested_within_while_expr() {
LL | | while &let 0 = 0 {}
= help: the trait `FromResidual<_>` is not implemented for `()`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:248:11
+ --> $DIR/disallowed-positions.rs:244:11
|
LL | while x = let 0 = 0 {}
| ^^^^^^^^^^^^^ expected `bool`, found `()`
| ~~
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:253:11
+ --> $DIR/disallowed-positions.rs:249:11
|
LL | while true..(let 0 = 0) {}
| ^^^^^^^^^^^^^^^^^ expected `bool`, found struct `std::ops::Range`
found struct `std::ops::Range<bool>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:257:11
+ --> $DIR/disallowed-positions.rs:253:11
|
LL | while ..(let 0 = 0) {}
| ^^^^^^^^^^^^^ expected `bool`, found struct `RangeTo`
found struct `RangeTo<bool>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:261:11
+ --> $DIR/disallowed-positions.rs:257:11
|
LL | while (let 0 = 0).. {}
| ^^^^^^^^^^^^^ expected `bool`, found struct `RangeFrom`
found struct `RangeFrom<bool>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:267:15
+ --> $DIR/disallowed-positions.rs:263:15
|
LL | while let Range { start: _, end: _ } = true..true && false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^ ---- this expression has type `bool`
found struct `std::ops::Range<_>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:267:11
+ --> $DIR/disallowed-positions.rs:263:11
|
LL | while let Range { start: _, end: _ } = true..true && false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found struct `std::ops::Range`
found struct `std::ops::Range<bool>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:271:15
+ --> $DIR/disallowed-positions.rs:267:15
|
LL | while let Range { start: _, end: _ } = true..true || false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^ ---- this expression has type `bool`
found struct `std::ops::Range<_>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:271:11
+ --> $DIR/disallowed-positions.rs:267:11
|
LL | while let Range { start: _, end: _ } = true..true || false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found struct `std::ops::Range`
found struct `std::ops::Range<bool>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:278:15
+ --> $DIR/disallowed-positions.rs:274:15
|
LL | while let Range { start: F, end } = F..|| true {}
| ^^^^^^^^^^^^^^^^^^^^^^^ - this expression has type `fn() -> bool`
found struct `std::ops::Range<_>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:278:44
+ --> $DIR/disallowed-positions.rs:274:44
|
LL | while let Range { start: F, end } = F..|| true {}
| ^^^^^^^ expected `bool`, found closure
|
= note: expected type `bool`
- found closure `[closure@$DIR/disallowed-positions.rs:278:44: 278:46]`
+ found closure `[closure@$DIR/disallowed-positions.rs:274:44: 274:46]`
help: use parentheses to call this closure
|
LL | while let Range { start: F, end } = F..(|| true)() {}
| + +++
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:278:11
+ --> $DIR/disallowed-positions.rs:274:11
|
LL | while let Range { start: F, end } = F..|| true {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found struct `std::ops::Range`
found struct `std::ops::Range<bool>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:286:15
+ --> $DIR/disallowed-positions.rs:282:15
|
LL | while let Range { start: true, end } = t..&&false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^ - this expression has type `&&bool`
found struct `std::ops::Range<_>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:286:47
+ --> $DIR/disallowed-positions.rs:282:47
|
LL | while let Range { start: true, end } = t..&&false {}
| ^^^^^^^ expected `bool`, found `&&bool`
|
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:286:11
+ --> $DIR/disallowed-positions.rs:282:11
|
LL | while let Range { start: true, end } = t..&&false {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found struct `std::ops::Range`
found struct `std::ops::Range<bool>`
error[E0277]: the `?` operator can only be applied to values that implement `Try`
- --> $DIR/disallowed-positions.rs:224:23
+ --> $DIR/disallowed-positions.rs:220:23
|
LL | while let 0 = 0? {}
| ^^ the `?` operator cannot be applied to type `{integer}`
= help: the trait `Try` is not implemented for `{integer}`
error[E0614]: type `bool` cannot be dereferenced
- --> $DIR/disallowed-positions.rs:315:5
+ --> $DIR/disallowed-positions.rs:311:5
|
LL | *let 0 = 0;
| ^^^^^^^^^^
error[E0600]: cannot apply unary operator `-` to type `bool`
- --> $DIR/disallowed-positions.rs:319:5
+ --> $DIR/disallowed-positions.rs:315:5
|
LL | -let 0 = 0;
| ^^^^^^^^^^ cannot apply unary operator `-`
error[E0277]: the `?` operator can only be applied to values that implement `Try`
- --> $DIR/disallowed-positions.rs:329:5
+ --> $DIR/disallowed-positions.rs:325:5
|
LL | (let 0 = 0)?;
| ^^^^^^^^^^^^ the `?` operator cannot be applied to type `bool`
= help: the trait `Try` is not implemented for `bool`
error[E0277]: the `?` operator can only be used in a function that returns `Result` or `Option` (or another type that implements `FromResidual`)
- --> $DIR/disallowed-positions.rs:329:16
+ --> $DIR/disallowed-positions.rs:325:16
|
LL | / fn outside_if_and_while_expr() {
LL | | &let 0 = 0;
= help: the trait `FromResidual<_>` is not implemented for `()`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:360:10
+ --> $DIR/disallowed-positions.rs:356:10
|
LL | (let Range { start: _, end: _ } = true..true || false);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^ ---- this expression has type `bool`
found struct `std::ops::Range<_>`
error[E0308]: mismatched types
- --> $DIR/disallowed-positions.rs:383:5
+ --> $DIR/disallowed-positions.rs:379:5
|
LL | fn outside_if_and_while_expr() {
| - help: try adding a return type: `-> &bool`
| ^^^^^^^^^^ expected `()`, found `&bool`
error[E0277]: the `?` operator can only be applied to values that implement `Try`
- --> $DIR/disallowed-positions.rs:325:17
+ --> $DIR/disallowed-positions.rs:321:17
|
LL | let 0 = 0?;
| ^^ the `?` operator cannot be applied to type `{integer}`
|
= help: the trait `Try` is not implemented for `{integer}`
-error: aborting due to 218 previous errors
+error: aborting due to 215 previous errors
Some errors have detailed explanations: E0277, E0308, E0600, E0614.
For more information about an error, try `rustc --explain E0277`.