fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1error: expected expression, found `let` statement 2 --> $DIR/disallowed-positions.rs:29:9 3 | 4LL | if (let 0 = 1) {} 5 | ^^^^^^^^^ 6 | 7 = note: only supported directly in conditions of `if` and `while` expressions 8note: `let`s wrapped in parentheses are not supported in a context with let chains 9 --> $DIR/disallowed-positions.rs:29:9 10 | 11LL | if (let 0 = 1) {} 12 | ^^^^^^^^^ 13 14error: expected expression, found `let` statement 15 --> $DIR/disallowed-positions.rs:32:11 16 | 17LL | if (((let 0 = 1))) {} 18 | ^^^^^^^^^ 19 | 20 = note: only supported directly in conditions of `if` and `while` expressions 21note: `let`s wrapped in parentheses are not supported in a context with let chains 22 --> $DIR/disallowed-positions.rs:32:11 23 | 24LL | if (((let 0 = 1))) {} 25 | ^^^^^^^^^ 26 27error: expected expression, found `let` statement 28 --> $DIR/disallowed-positions.rs:35:9 29 | 30LL | if (let 0 = 1) && true {} 31 | ^^^^^^^^^ 32 | 33 = note: only supported directly in conditions of `if` and `while` expressions 34note: `let`s wrapped in parentheses are not supported in a context with let chains 35 --> $DIR/disallowed-positions.rs:35:9 36 | 37LL | if (let 0 = 1) && true {} 38 | ^^^^^^^^^ 39 40error: expected expression, found `let` statement 41 --> $DIR/disallowed-positions.rs:38:17 42 | 43LL | if true && (let 0 = 1) {} 44 | ^^^^^^^^^ 45 | 46 = note: only supported directly in conditions of `if` and `while` expressions 47note: `let`s wrapped in parentheses are not supported in a context with let chains 48 --> $DIR/disallowed-positions.rs:38:17 49 | 50LL | if true && (let 0 = 1) {} 51 | ^^^^^^^^^ 52 53error: expected expression, found `let` statement 54 --> $DIR/disallowed-positions.rs:41:9 55 | 56LL | if (let 0 = 1) && (let 0 = 1) {} 57 | ^^^^^^^^^ 58 | 59 = note: only supported directly in conditions of `if` and `while` expressions 60note: `let`s wrapped in parentheses are not supported in a context with let chains 61 --> $DIR/disallowed-positions.rs:41:9 62 | 63LL | if (let 0 = 1) && (let 0 = 1) {} 64 | ^^^^^^^^^ 65 66error: expected expression, found `let` statement 67 --> $DIR/disallowed-positions.rs:41:24 68 | 69LL | if (let 0 = 1) && (let 0 = 1) {} 70 | ^^^^^^^^^ 71 | 72 = note: only supported directly in conditions of `if` and `while` expressions 73note: `let`s wrapped in parentheses are not supported in a context with let chains 74 --> $DIR/disallowed-positions.rs:41:24 75 | 76LL | if (let 0 = 1) && (let 0 = 1) {} 77 | ^^^^^^^^^ 78 79error: expected expression, found `let` statement 80 --> $DIR/disallowed-positions.rs:45:35 81 | 82LL | if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {} 83 | ^^^^^^^^^ 84 | 85 = note: only supported directly in conditions of `if` and `while` expressions 86note: `let`s wrapped in parentheses are not supported in a context with let chains 87 --> $DIR/disallowed-positions.rs:45:35 88 | 89LL | if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {} 90 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 91 92error: expected expression, found `let` statement 93 --> $DIR/disallowed-positions.rs:45:48 94 | 95LL | if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {} 96 | ^^^^^^^^^ 97 | 98 = note: only supported directly in conditions of `if` and `while` expressions 99note: `let`s wrapped in parentheses are not supported in a context with let chains 100 --> $DIR/disallowed-positions.rs:45:35 101 | 102LL | if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {} 103 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 104 105error: expected expression, found `let` statement 106 --> $DIR/disallowed-positions.rs:45:61 107 | 108LL | if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {} 109 | ^^^^^^^^^ 110 | 111 = note: only supported directly in conditions of `if` and `while` expressions 112note: `let`s wrapped in parentheses are not supported in a context with let chains 113 --> $DIR/disallowed-positions.rs:45:35 114 | 115LL | if let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {} 116 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 117 118error: expected expression, found `let` statement 119 --> $DIR/disallowed-positions.rs:52:12 120 | 121LL | while (let 0 = 1) {} 122 | ^^^^^^^^^ 123 | 124 = note: only supported directly in conditions of `if` and `while` expressions 125note: `let`s wrapped in parentheses are not supported in a context with let chains 126 --> $DIR/disallowed-positions.rs:52:12 127 | 128LL | while (let 0 = 1) {} 129 | ^^^^^^^^^ 130 131error: expected expression, found `let` statement 132 --> $DIR/disallowed-positions.rs:55:14 133 | 134LL | while (((let 0 = 1))) {} 135 | ^^^^^^^^^ 136 | 137 = note: only supported directly in conditions of `if` and `while` expressions 138note: `let`s wrapped in parentheses are not supported in a context with let chains 139 --> $DIR/disallowed-positions.rs:55:14 140 | 141LL | while (((let 0 = 1))) {} 142 | ^^^^^^^^^ 143 144error: expected expression, found `let` statement 145 --> $DIR/disallowed-positions.rs:58:12 146 | 147LL | while (let 0 = 1) && true {} 148 | ^^^^^^^^^ 149 | 150 = note: only supported directly in conditions of `if` and `while` expressions 151note: `let`s wrapped in parentheses are not supported in a context with let chains 152 --> $DIR/disallowed-positions.rs:58:12 153 | 154LL | while (let 0 = 1) && true {} 155 | ^^^^^^^^^ 156 157error: expected expression, found `let` statement 158 --> $DIR/disallowed-positions.rs:61:20 159 | 160LL | while true && (let 0 = 1) {} 161 | ^^^^^^^^^ 162 | 163 = note: only supported directly in conditions of `if` and `while` expressions 164note: `let`s wrapped in parentheses are not supported in a context with let chains 165 --> $DIR/disallowed-positions.rs:61:20 166 | 167LL | while true && (let 0 = 1) {} 168 | ^^^^^^^^^ 169 170error: expected expression, found `let` statement 171 --> $DIR/disallowed-positions.rs:64:12 172 | 173LL | while (let 0 = 1) && (let 0 = 1) {} 174 | ^^^^^^^^^ 175 | 176 = note: only supported directly in conditions of `if` and `while` expressions 177note: `let`s wrapped in parentheses are not supported in a context with let chains 178 --> $DIR/disallowed-positions.rs:64:12 179 | 180LL | while (let 0 = 1) && (let 0 = 1) {} 181 | ^^^^^^^^^ 182 183error: expected expression, found `let` statement 184 --> $DIR/disallowed-positions.rs:64:27 185 | 186LL | while (let 0 = 1) && (let 0 = 1) {} 187 | ^^^^^^^^^ 188 | 189 = note: only supported directly in conditions of `if` and `while` expressions 190note: `let`s wrapped in parentheses are not supported in a context with let chains 191 --> $DIR/disallowed-positions.rs:64:27 192 | 193LL | while (let 0 = 1) && (let 0 = 1) {} 194 | ^^^^^^^^^ 195 196error: expected expression, found `let` statement 197 --> $DIR/disallowed-positions.rs:68:38 198 | 199LL | while let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {} 200 | ^^^^^^^^^ 201 | 202 = note: only supported directly in conditions of `if` and `while` expressions 203note: `let`s wrapped in parentheses are not supported in a context with let chains 204 --> $DIR/disallowed-positions.rs:68:38 205 | 206LL | while let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {} 207 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 208 209error: expected expression, found `let` statement 210 --> $DIR/disallowed-positions.rs:68:51 211 | 212LL | while let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {} 213 | ^^^^^^^^^ 214 | 215 = note: only supported directly in conditions of `if` and `while` expressions 216note: `let`s wrapped in parentheses are not supported in a context with let chains 217 --> $DIR/disallowed-positions.rs:68:38 218 | 219LL | while let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {} 220 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 221 222error: expected expression, found `let` statement 223 --> $DIR/disallowed-positions.rs:68:64 224 | 225LL | while let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {} 226 | ^^^^^^^^^ 227 | 228 = note: only supported directly in conditions of `if` and `while` expressions 229note: `let`s wrapped in parentheses are not supported in a context with let chains 230 --> $DIR/disallowed-positions.rs:68:38 231 | 232LL | while let 0 = 1 && let 1 = 2 && (let 2 = 3 && let 3 = 4 && let 4 = 5) {} 233 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 234 235error: expected expression, found `let` statement 236 --> $DIR/disallowed-positions.rs:88:9 237 | 238LL | if &let 0 = 0 {} 239 | ^^^^^^^^^ 240 | 241 = note: only supported directly in conditions of `if` and `while` expressions 242 243error: expected expression, found `let` statement 244 --> $DIR/disallowed-positions.rs:91:9 245 | 246LL | if !let 0 = 0 {} 247 | ^^^^^^^^^ 248 | 249 = note: only supported directly in conditions of `if` and `while` expressions 250 251error: expected expression, found `let` statement 252 --> $DIR/disallowed-positions.rs:93:9 253 | 254LL | if *let 0 = 0 {} 255 | ^^^^^^^^^ 256 | 257 = note: only supported directly in conditions of `if` and `while` expressions 258 259error: expected expression, found `let` statement 260 --> $DIR/disallowed-positions.rs:95:9 261 | 262LL | if -let 0 = 0 {} 263 | ^^^^^^^^^ 264 | 265 = note: only supported directly in conditions of `if` and `while` expressions 266 267error: expected expression, found `let` statement 268 --> $DIR/disallowed-positions.rs:103:9 269 | 270LL | if (let 0 = 0)? {} 271 | ^^^^^^^^^ 272 | 273 = note: only supported directly in conditions of `if` and `while` expressions 274 275error: expected expression, found `let` statement 276 --> $DIR/disallowed-positions.rs:106:16 277 | 278LL | if true || let 0 = 0 {} 279 | ^^^^^^^^^ 280 | 281 = note: only supported directly in conditions of `if` and `while` expressions 282note: `||` operators are not supported in let chain expressions 283 --> $DIR/disallowed-positions.rs:106:13 284 | 285LL | if true || let 0 = 0 {} 286 | ^^ 287 288error: expected expression, found `let` statement 289 --> $DIR/disallowed-positions.rs:108:17 290 | 291LL | if (true || let 0 = 0) {} 292 | ^^^^^^^^^ 293 | 294 = note: only supported directly in conditions of `if` and `while` expressions 295 296error: expected expression, found `let` statement 297 --> $DIR/disallowed-positions.rs:110:25 298 | 299LL | if true && (true || let 0 = 0) {} 300 | ^^^^^^^^^ 301 | 302 = note: only supported directly in conditions of `if` and `while` expressions 303 304error: expected expression, found `let` statement 305 --> $DIR/disallowed-positions.rs:112:25 306 | 307LL | if true || (true && let 0 = 0) {} 308 | ^^^^^^^^^ 309 | 310 = note: only supported directly in conditions of `if` and `while` expressions 311 312error: expected expression, found `let` statement 313 --> $DIR/disallowed-positions.rs:116:12 314 | 315LL | if x = let 0 = 0 {} 316 | ^^^ 317 | 318 = note: only supported directly in conditions of `if` and `while` expressions 319 320error: expected expression, found `let` statement 321 --> $DIR/disallowed-positions.rs:119:15 322 | 323LL | if true..(let 0 = 0) {} 324 | ^^^^^^^^^ 325 | 326 = note: only supported directly in conditions of `if` and `while` expressions 327 328error: expected expression, found `let` statement 329 --> $DIR/disallowed-positions.rs:122:11 330 | 331LL | if ..(let 0 = 0) {} 332 | ^^^^^^^^^ 333 | 334 = note: only supported directly in conditions of `if` and `while` expressions 335 336error: expected expression, found `let` statement 337 --> $DIR/disallowed-positions.rs:124:9 338 | 339LL | if (let 0 = 0).. {} 340 | ^^^^^^^^^ 341 | 342 = note: only supported directly in conditions of `if` and `while` expressions 343 344error: expected expression, found `let` statement 345 --> $DIR/disallowed-positions.rs:128:8 346 | 347LL | if let Range { start: _, end: _ } = true..true && false {} 348 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 349 | 350 = note: only supported directly in conditions of `if` and `while` expressions 351 352error: expected expression, found `let` statement 353 --> $DIR/disallowed-positions.rs:131:8 354 | 355LL | if let Range { start: _, end: _ } = true..true || false {} 356 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 357 | 358 = note: only supported directly in conditions of `if` and `while` expressions 359 360error: expected expression, found `let` statement 361 --> $DIR/disallowed-positions.rs:137:8 362 | 363LL | if let Range { start: F, end } = F..|| true {} 364 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 365 | 366 = note: only supported directly in conditions of `if` and `while` expressions 367 368error: expected expression, found `let` statement 369 --> $DIR/disallowed-positions.rs:143:8 370 | 371LL | if let Range { start: true, end } = t..&&false {} 372 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 373 | 374 = note: only supported directly in conditions of `if` and `while` expressions 375 376error: expected expression, found `let` statement 377 --> $DIR/disallowed-positions.rs:147:19 378 | 379LL | if let true = let true = true {} 380 | ^^^ 381 | 382 = note: only supported directly in conditions of `if` and `while` expressions 383 384error: expected expression, found `let` statement 385 --> $DIR/disallowed-positions.rs:152:12 386 | 387LL | while &let 0 = 0 {} 388 | ^^^^^^^^^ 389 | 390 = note: only supported directly in conditions of `if` and `while` expressions 391 392error: expected expression, found `let` statement 393 --> $DIR/disallowed-positions.rs:155:12 394 | 395LL | while !let 0 = 0 {} 396 | ^^^^^^^^^ 397 | 398 = note: only supported directly in conditions of `if` and `while` expressions 399 400error: expected expression, found `let` statement 401 --> $DIR/disallowed-positions.rs:157:12 402 | 403LL | while *let 0 = 0 {} 404 | ^^^^^^^^^ 405 | 406 = note: only supported directly in conditions of `if` and `while` expressions 407 408error: expected expression, found `let` statement 409 --> $DIR/disallowed-positions.rs:159:12 410 | 411LL | while -let 0 = 0 {} 412 | ^^^^^^^^^ 413 | 414 = note: only supported directly in conditions of `if` and `while` expressions 415 416error: expected expression, found `let` statement 417 --> $DIR/disallowed-positions.rs:167:12 418 | 419LL | while (let 0 = 0)? {} 420 | ^^^^^^^^^ 421 | 422 = note: only supported directly in conditions of `if` and `while` expressions 423 424error: expected expression, found `let` statement 425 --> $DIR/disallowed-positions.rs:170:19 426 | 427LL | while true || let 0 = 0 {} 428 | ^^^^^^^^^ 429 | 430 = note: only supported directly in conditions of `if` and `while` expressions 431note: `||` operators are not supported in let chain expressions 432 --> $DIR/disallowed-positions.rs:170:16 433 | 434LL | while true || let 0 = 0 {} 435 | ^^ 436 437error: expected expression, found `let` statement 438 --> $DIR/disallowed-positions.rs:172:20 439 | 440LL | while (true || let 0 = 0) {} 441 | ^^^^^^^^^ 442 | 443 = note: only supported directly in conditions of `if` and `while` expressions 444 445error: expected expression, found `let` statement 446 --> $DIR/disallowed-positions.rs:174:28 447 | 448LL | while true && (true || let 0 = 0) {} 449 | ^^^^^^^^^ 450 | 451 = note: only supported directly in conditions of `if` and `while` expressions 452 453error: expected expression, found `let` statement 454 --> $DIR/disallowed-positions.rs:176:28 455 | 456LL | while true || (true && let 0 = 0) {} 457 | ^^^^^^^^^ 458 | 459 = note: only supported directly in conditions of `if` and `while` expressions 460 461error: expected expression, found `let` statement 462 --> $DIR/disallowed-positions.rs:180:15 463 | 464LL | while x = let 0 = 0 {} 465 | ^^^ 466 | 467 = note: only supported directly in conditions of `if` and `while` expressions 468 469error: expected expression, found `let` statement 470 --> $DIR/disallowed-positions.rs:183:18 471 | 472LL | while true..(let 0 = 0) {} 473 | ^^^^^^^^^ 474 | 475 = note: only supported directly in conditions of `if` and `while` expressions 476 477error: expected expression, found `let` statement 478 --> $DIR/disallowed-positions.rs:186:14 479 | 480LL | while ..(let 0 = 0) {} 481 | ^^^^^^^^^ 482 | 483 = note: only supported directly in conditions of `if` and `while` expressions 484 485error: expected expression, found `let` statement 486 --> $DIR/disallowed-positions.rs:188:12 487 | 488LL | while (let 0 = 0).. {} 489 | ^^^^^^^^^ 490 | 491 = note: only supported directly in conditions of `if` and `while` expressions 492 493error: expected expression, found `let` statement 494 --> $DIR/disallowed-positions.rs:192:11 495 | 496LL | while let Range { start: _, end: _ } = true..true && false {} 497 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 498 | 499 = note: only supported directly in conditions of `if` and `while` expressions 500 501error: expected expression, found `let` statement 502 --> $DIR/disallowed-positions.rs:195:11 503 | 504LL | while let Range { start: _, end: _ } = true..true || false {} 505 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 506 | 507 = note: only supported directly in conditions of `if` and `while` expressions 508 509error: expected expression, found `let` statement 510 --> $DIR/disallowed-positions.rs:201:11 511 | 512LL | while let Range { start: F, end } = F..|| true {} 513 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 514 | 515 = note: only supported directly in conditions of `if` and `while` expressions 516 517error: expected expression, found `let` statement 518 --> $DIR/disallowed-positions.rs:207:11 519 | 520LL | while let Range { start: true, end } = t..&&false {} 521 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 522 | 523 = note: only supported directly in conditions of `if` and `while` expressions 524 525error: expected expression, found `let` statement 526 --> $DIR/disallowed-positions.rs:211:22 527 | 528LL | while let true = let true = true {} 529 | ^^^ 530 | 531 = note: only supported directly in conditions of `if` and `while` expressions 532 533error: expected expression, found `let` statement 534 --> $DIR/disallowed-positions.rs:226:6 535 | 536LL | &let 0 = 0; 537 | ^^^ 538 | 539 = note: only supported directly in conditions of `if` and `while` expressions 540 541error: expected expression, found `let` statement 542 --> $DIR/disallowed-positions.rs:229:6 543 | 544LL | !let 0 = 0; 545 | ^^^ 546 | 547 = note: only supported directly in conditions of `if` and `while` expressions 548 549error: expected expression, found `let` statement 550 --> $DIR/disallowed-positions.rs:231:6 551 | 552LL | *let 0 = 0; 553 | ^^^ 554 | 555 = note: only supported directly in conditions of `if` and `while` expressions 556 557error: expected expression, found `let` statement 558 --> $DIR/disallowed-positions.rs:233:6 559 | 560LL | -let 0 = 0; 561 | ^^^ 562 | 563 = note: only supported directly in conditions of `if` and `while` expressions 564 565error: expected expression, found `let` statement 566 --> $DIR/disallowed-positions.rs:241:6 567 | 568LL | (let 0 = 0)?; 569 | ^^^ 570 | 571 = note: only supported directly in conditions of `if` and `while` expressions 572 573error: expected expression, found `let` statement 574 --> $DIR/disallowed-positions.rs:244:13 575 | 576LL | true || let 0 = 0; 577 | ^^^ 578 | 579 = note: only supported directly in conditions of `if` and `while` expressions 580 581error: expected expression, found `let` statement 582 --> $DIR/disallowed-positions.rs:246:14 583 | 584LL | (true || let 0 = 0); 585 | ^^^ 586 | 587 = note: only supported directly in conditions of `if` and `while` expressions 588 589error: expected expression, found `let` statement 590 --> $DIR/disallowed-positions.rs:248:22 591 | 592LL | true && (true || let 0 = 0); 593 | ^^^ 594 | 595 = note: only supported directly in conditions of `if` and `while` expressions 596 597error: expected expression, found `let` statement 598 --> $DIR/disallowed-positions.rs:252:9 599 | 600LL | x = let 0 = 0; 601 | ^^^ 602 | 603 = note: only supported directly in conditions of `if` and `while` expressions 604 605error: expected expression, found `let` statement 606 --> $DIR/disallowed-positions.rs:255:12 607 | 608LL | true..(let 0 = 0); 609 | ^^^ 610 | 611 = note: only supported directly in conditions of `if` and `while` expressions 612 613error: expected expression, found `let` statement 614 --> $DIR/disallowed-positions.rs:257:8 615 | 616LL | ..(let 0 = 0); 617 | ^^^ 618 | 619 = note: only supported directly in conditions of `if` and `while` expressions 620 621error: expected expression, found `let` statement 622 --> $DIR/disallowed-positions.rs:259:6 623 | 624LL | (let 0 = 0)..; 625 | ^^^ 626 | 627 = note: only supported directly in conditions of `if` and `while` expressions 628 629error: expected expression, found `let` statement 630 --> $DIR/disallowed-positions.rs:262:6 631 | 632LL | (let Range { start: _, end: _ } = true..true || false); 633 | ^^^ 634 | 635 = note: only supported directly in conditions of `if` and `while` expressions 636 637error: expected expression, found `let` statement 638 --> $DIR/disallowed-positions.rs:266:6 639 | 640LL | (let true = let true = true); 641 | ^^^ 642 | 643 = note: only supported directly in conditions of `if` and `while` expressions 644 645error: expected expression, found `let` statement 646 --> $DIR/disallowed-positions.rs:266:17 647 | 648LL | (let true = let true = true); 649 | ^^^ 650 | 651 = note: only supported directly in conditions of `if` and `while` expressions 652 653error: expected expression, found `let` statement 654 --> $DIR/disallowed-positions.rs:272:25 655 | 656LL | let x = true && let y = 1; 657 | ^^^ 658 | 659 = note: only supported directly in conditions of `if` and `while` expressions 660 661error: expected expression, found `let` statement 662 --> $DIR/disallowed-positions.rs:278:19 663 | 664LL | [1, 2, 3][let _ = ()] 665 | ^^^ 666 | 667 = note: only supported directly in conditions of `if` and `while` expressions 668 669error: expected expression, found `let` statement 670 --> $DIR/disallowed-positions.rs:283:6 671 | 672LL | &let 0 = 0 673 | ^^^ 674 | 675 = note: only supported directly in conditions of `if` and `while` expressions 676 677error: expected expression, found `let` statement 678 --> $DIR/disallowed-positions.rs:293:17 679 | 680LL | true && let 1 = 1 681 | ^^^ 682 | 683 = note: only supported directly in conditions of `if` and `while` expressions 684 685error: expected expression, found `let` statement 686 --> $DIR/disallowed-positions.rs:298:17 687 | 688LL | true && let 1 = 1 689 | ^^^ 690 | 691 = note: only supported directly in conditions of `if` and `while` expressions 692 693error: expected expression, found `let` statement 694 --> $DIR/disallowed-positions.rs:303:17 695 | 696LL | true && let 1 = 1 697 | ^^^ 698 | 699 = note: only supported directly in conditions of `if` and `while` expressions 700 701error: expected expression, found `let` statement 702 --> $DIR/disallowed-positions.rs:314:17 703 | 704LL | true && let 1 = 1 705 | ^^^ 706 | 707 = note: only supported directly in conditions of `if` and `while` expressions 708 709error: expressions must be enclosed in braces to be used as const generic arguments 710 --> $DIR/disallowed-positions.rs:314:9 711 | 712LL | true && let 1 = 1 713 | ^^^^^^^^^^^^^^^^^ 714 | 715help: enclose the `const` expression in braces 716 | 717LL | { true && let 1 = 1 } 718 | + + 719 720error: expected expression, found `let` statement 721 --> $DIR/disallowed-positions.rs:323:9 722 | 723LL | if (let Some(a) = opt && true) { 724 | ^^^^^^^^^^^^^^^^^ 725 | 726 = note: only supported directly in conditions of `if` and `while` expressions 727note: `let`s wrapped in parentheses are not supported in a context with let chains 728 --> $DIR/disallowed-positions.rs:323:9 729 | 730LL | if (let Some(a) = opt && true) { 731 | ^^^^^^^^^^^^^^^^^^^^^^^^^ 732 733error: expected expression, found `let` statement 734 --> $DIR/disallowed-positions.rs:327:9 735 | 736LL | if (let Some(a) = opt) && true { 737 | ^^^^^^^^^^^^^^^^^ 738 | 739 = note: only supported directly in conditions of `if` and `while` expressions 740note: `let`s wrapped in parentheses are not supported in a context with let chains 741 --> $DIR/disallowed-positions.rs:327:9 742 | 743LL | if (let Some(a) = opt) && true { 744 | ^^^^^^^^^^^^^^^^^ 745 746error: expected expression, found `let` statement 747 --> $DIR/disallowed-positions.rs:330:9 748 | 749LL | if (let Some(a) = opt) && (let Some(b) = a) { 750 | ^^^^^^^^^^^^^^^^^ 751 | 752 = note: only supported directly in conditions of `if` and `while` expressions 753note: `let`s wrapped in parentheses are not supported in a context with let chains 754 --> $DIR/disallowed-positions.rs:330:9 755 | 756LL | if (let Some(a) = opt) && (let Some(b) = a) { 757 | ^^^^^^^^^^^^^^^^^ 758 759error: expected expression, found `let` statement 760 --> $DIR/disallowed-positions.rs:330:32 761 | 762LL | if (let Some(a) = opt) && (let Some(b) = a) { 763 | ^^^^^^^^^^^^^^^ 764 | 765 = note: only supported directly in conditions of `if` and `while` expressions 766note: `let`s wrapped in parentheses are not supported in a context with let chains 767 --> $DIR/disallowed-positions.rs:330:32 768 | 769LL | if (let Some(a) = opt) && (let Some(b) = a) { 770 | ^^^^^^^^^^^^^^^ 771 772error: expected expression, found `let` statement 773 --> $DIR/disallowed-positions.rs:337:9 774 | 775LL | if (let Some(a) = opt && (let Some(b) = a)) && b == 1 { 776 | ^^^^^^^^^^^^^^^^^ 777 | 778 = note: only supported directly in conditions of `if` and `while` expressions 779note: `let`s wrapped in parentheses are not supported in a context with let chains 780 --> $DIR/disallowed-positions.rs:337:9 781 | 782LL | if (let Some(a) = opt && (let Some(b) = a)) && b == 1 { 783 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 784 785error: expected expression, found `let` statement 786 --> $DIR/disallowed-positions.rs:337:31 787 | 788LL | if (let Some(a) = opt && (let Some(b) = a)) && b == 1 { 789 | ^^^^^^^^^^^^^^^ 790 | 791 = note: only supported directly in conditions of `if` and `while` expressions 792note: `let`s wrapped in parentheses are not supported in a context with let chains 793 --> $DIR/disallowed-positions.rs:337:31 794 | 795LL | if (let Some(a) = opt && (let Some(b) = a)) && b == 1 { 796 | ^^^^^^^^^^^^^^^ 797 798error: expected expression, found `let` statement 799 --> $DIR/disallowed-positions.rs:341:9 800 | 801LL | if (let Some(a) = opt && (let Some(b) = a)) && true { 802 | ^^^^^^^^^^^^^^^^^ 803 | 804 = note: only supported directly in conditions of `if` and `while` expressions 805note: `let`s wrapped in parentheses are not supported in a context with let chains 806 --> $DIR/disallowed-positions.rs:341:9 807 | 808LL | if (let Some(a) = opt && (let Some(b) = a)) && true { 809 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 810 811error: expected expression, found `let` statement 812 --> $DIR/disallowed-positions.rs:341:31 813 | 814LL | if (let Some(a) = opt && (let Some(b) = a)) && true { 815 | ^^^^^^^^^^^^^^^ 816 | 817 = note: only supported directly in conditions of `if` and `while` expressions 818note: `let`s wrapped in parentheses are not supported in a context with let chains 819 --> $DIR/disallowed-positions.rs:341:31 820 | 821LL | if (let Some(a) = opt && (let Some(b) = a)) && true { 822 | ^^^^^^^^^^^^^^^ 823 824error: expected expression, found `let` statement 825 --> $DIR/disallowed-positions.rs:345:9 826 | 827LL | if (let Some(a) = opt && (true)) && true { 828 | ^^^^^^^^^^^^^^^^^ 829 | 830 = note: only supported directly in conditions of `if` and `while` expressions 831note: `let`s wrapped in parentheses are not supported in a context with let chains 832 --> $DIR/disallowed-positions.rs:345:9 833 | 834LL | if (let Some(a) = opt && (true)) && true { 835 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ 836 837error: expected expression, found `let` statement 838 --> $DIR/disallowed-positions.rs:361:22 839 | 840LL | let x = (true && let y = 1); 841 | ^^^ 842 | 843 = note: only supported directly in conditions of `if` and `while` expressions 844 845error: expected expression, found `let` statement 846 --> $DIR/disallowed-positions.rs:366:20 847 | 848LL | ([1, 2, 3][let _ = ()]) 849 | ^^^ 850 | 851 = note: only supported directly in conditions of `if` and `while` expressions 852 853error: expected expression, found `let` statement 854 --> $DIR/disallowed-positions.rs:81:16 855 | 856LL | use_expr!((let 0 = 1 && 0 == 0)); 857 | ^^^ 858 | 859 = note: only supported directly in conditions of `if` and `while` expressions 860 861error: expected expression, found `let` statement 862 --> $DIR/disallowed-positions.rs:83:16 863 | 864LL | use_expr!((let 0 = 1)); 865 | ^^^ 866 | 867 = note: only supported directly in conditions of `if` and `while` expressions 868 869error[E0308]: mismatched types 870 --> $DIR/disallowed-positions.rs:119:8 871 | 872LL | if true..(let 0 = 0) {} 873 | ^^^^^^^^^^^^^^^^^ expected `bool`, found `Range<bool>` 874 | 875 = note: expected type `bool` 876 found struct `std::ops::Range<bool>` 877 878error[E0308]: mismatched types 879 --> $DIR/disallowed-positions.rs:128:12 880 | 881LL | if let Range { start: _, end: _ } = true..true && false {} 882 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ ---- this expression has type `bool` 883 | | 884 | expected `bool`, found `Range<_>` 885 | 886 = note: expected type `bool` 887 found struct `std::ops::Range<_>` 888 889error[E0308]: mismatched types 890 --> $DIR/disallowed-positions.rs:131:12 891 | 892LL | if let Range { start: _, end: _ } = true..true || false {} 893 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ ---- this expression has type `bool` 894 | | 895 | expected `bool`, found `Range<_>` 896 | 897 = note: expected type `bool` 898 found struct `std::ops::Range<_>` 899 900error[E0308]: mismatched types 901 --> $DIR/disallowed-positions.rs:137:12 902 | 903LL | if let Range { start: F, end } = F..|| true {} 904 | ^^^^^^^^^^^^^^^^^^^^^^^ - this expression has type `fn() -> bool` 905 | | 906 | expected fn pointer, found `Range<_>` 907 | 908 = note: expected fn pointer `fn() -> bool` 909 found struct `std::ops::Range<_>` 910 911error[E0308]: mismatched types 912 --> $DIR/disallowed-positions.rs:143:12 913 | 914LL | if let Range { start: true, end } = t..&&false {} 915 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ - this expression has type `&&bool` 916 | | 917 | expected `bool`, found `Range<_>` 918 | 919 = note: expected type `bool` 920 found struct `std::ops::Range<_>` 921 922error[E0277]: the `?` operator can only be applied to values that implement `Try` 923 --> $DIR/disallowed-positions.rs:99:20 924 | 925LL | if let 0 = 0? {} 926 | ^^ the `?` operator cannot be applied to type `{integer}` 927 | 928 = help: the trait `Try` is not implemented for `{integer}` 929 930error[E0308]: mismatched types 931 --> $DIR/disallowed-positions.rs:183:11 932 | 933LL | while true..(let 0 = 0) {} 934 | ^^^^^^^^^^^^^^^^^ expected `bool`, found `Range<bool>` 935 | 936 = note: expected type `bool` 937 found struct `std::ops::Range<bool>` 938 939error[E0308]: mismatched types 940 --> $DIR/disallowed-positions.rs:192:15 941 | 942LL | while let Range { start: _, end: _ } = true..true && false {} 943 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ ---- this expression has type `bool` 944 | | 945 | expected `bool`, found `Range<_>` 946 | 947 = note: expected type `bool` 948 found struct `std::ops::Range<_>` 949 950error[E0308]: mismatched types 951 --> $DIR/disallowed-positions.rs:195:15 952 | 953LL | while let Range { start: _, end: _ } = true..true || false {} 954 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ ---- this expression has type `bool` 955 | | 956 | expected `bool`, found `Range<_>` 957 | 958 = note: expected type `bool` 959 found struct `std::ops::Range<_>` 960 961error[E0308]: mismatched types 962 --> $DIR/disallowed-positions.rs:201:15 963 | 964LL | while let Range { start: F, end } = F..|| true {} 965 | ^^^^^^^^^^^^^^^^^^^^^^^ - this expression has type `fn() -> bool` 966 | | 967 | expected fn pointer, found `Range<_>` 968 | 969 = note: expected fn pointer `fn() -> bool` 970 found struct `std::ops::Range<_>` 971 972error[E0308]: mismatched types 973 --> $DIR/disallowed-positions.rs:207:15 974 | 975LL | while let Range { start: true, end } = t..&&false {} 976 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ - this expression has type `&&bool` 977 | | 978 | expected `bool`, found `Range<_>` 979 | 980 = note: expected type `bool` 981 found struct `std::ops::Range<_>` 982 983error[E0277]: the `?` operator can only be applied to values that implement `Try` 984 --> $DIR/disallowed-positions.rs:163:23 985 | 986LL | while let 0 = 0? {} 987 | ^^ the `?` operator cannot be applied to type `{integer}` 988 | 989 = help: the trait `Try` is not implemented for `{integer}` 990 991error[E0308]: mismatched types 992 --> $DIR/disallowed-positions.rs:262:10 993 | 994LL | (let Range { start: _, end: _ } = true..true || false); 995 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ ---- this expression has type `bool` 996 | | 997 | expected `bool`, found `Range<_>` 998 | 999 = note: expected type `bool` 1000 found struct `std::ops::Range<_>` 1001 1002error[E0277]: the `?` operator can only be applied to values that implement `Try` 1003 --> $DIR/disallowed-positions.rs:237:17 1004 | 1005LL | let 0 = 0?; 1006 | ^^ the `?` operator cannot be applied to type `{integer}` 1007 | 1008 = help: the trait `Try` is not implemented for `{integer}` 1009 1010error: aborting due to 104 previous errors 1011 1012Some errors have detailed explanations: E0277, E0308. 1013For more information about an error, try `rustc --explain E0277`.