fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1error: label without `#[primary_span]` field 2 --> $DIR/subdiagnostic-derive.rs:52:1 3 | 4LL | / #[label(no_crate_example)] 5LL | | 6LL | | struct C { 7LL | | var: String, 8LL | | } 9 | |_^ 10 11error: diagnostic slug must be first argument of a `#[label(...)]` attribute 12 --> $DIR/subdiagnostic-derive.rs:59:1 13 | 14LL | #[label] 15 | ^^^^^^^^ 16 17error: `#[foo]` is not a valid attribute 18 --> $DIR/subdiagnostic-derive.rs:68:1 19 | 20LL | #[foo] 21 | ^^^^^^ 22 23error: `#[label = ...]` is not a valid attribute 24 --> $DIR/subdiagnostic-derive.rs:78:1 25 | 26LL | #[label = "..."] 27 | ^^^^^^^^^^^^^^^^ 28 29error: only `no_span` is a valid nested attribute 30 --> $DIR/subdiagnostic-derive.rs:87:9 31 | 32LL | #[label(bug = "...")] 33 | ^^^ 34 35error: diagnostic slug must be first argument of a `#[label(...)]` attribute 36 --> $DIR/subdiagnostic-derive.rs:87:1 37 | 38LL | #[label(bug = "...")] 39 | ^^^^^^^^^^^^^^^^^^^^^ 40 41error: only `no_span` is a valid nested attribute 42 --> $DIR/subdiagnostic-derive.rs:107:9 43 | 44LL | #[label(slug = 4)] 45 | ^^^^ 46 47error: diagnostic slug must be first argument of a `#[label(...)]` attribute 48 --> $DIR/subdiagnostic-derive.rs:107:1 49 | 50LL | #[label(slug = 4)] 51 | ^^^^^^^^^^^^^^^^^^ 52 53error: only `no_span` is a valid nested attribute 54 --> $DIR/subdiagnostic-derive.rs:117:9 55 | 56LL | #[label(slug("..."))] 57 | ^^^^ 58 59error: diagnostic slug must be first argument of a `#[label(...)]` attribute 60 --> $DIR/subdiagnostic-derive.rs:117:1 61 | 62LL | #[label(slug("..."))] 63 | ^^^^^^^^^^^^^^^^^^^^^ 64 65error: diagnostic slug must be first argument of a `#[label(...)]` attribute 66 --> $DIR/subdiagnostic-derive.rs:137:1 67 | 68LL | #[label()] 69 | ^^^^^^^^^^ 70 71error: only `no_span` is a valid nested attribute 72 --> $DIR/subdiagnostic-derive.rs:146:27 73 | 74LL | #[label(no_crate_example, code = "...")] 75 | ^^^^ 76 77error: only `no_span` is a valid nested attribute 78 --> $DIR/subdiagnostic-derive.rs:155:27 79 | 80LL | #[label(no_crate_example, applicability = "machine-applicable")] 81 | ^^^^^^^^^^^^^ 82 83error: unsupported type attribute for subdiagnostic enum 84 --> $DIR/subdiagnostic-derive.rs:164:1 85 | 86LL | #[foo] 87 | ^^^^^^ 88 89error: `#[bar]` is not a valid attribute 90 --> $DIR/subdiagnostic-derive.rs:178:5 91 | 92LL | #[bar] 93 | ^^^^^^ 94 95error: `#[bar = ...]` is not a valid attribute 96 --> $DIR/subdiagnostic-derive.rs:190:5 97 | 98LL | #[bar = "..."] 99 | ^^^^^^^^^^^^^^ 100 101error: `#[bar = ...]` is not a valid attribute 102 --> $DIR/subdiagnostic-derive.rs:202:5 103 | 104LL | #[bar = 4] 105 | ^^^^^^^^^^ 106 107error: `#[bar(...)]` is not a valid attribute 108 --> $DIR/subdiagnostic-derive.rs:214:5 109 | 110LL | #[bar("...")] 111 | ^^^^^^^^^^^^^ 112 113error: only `no_span` is a valid nested attribute 114 --> $DIR/subdiagnostic-derive.rs:226:13 115 | 116LL | #[label(code = "...")] 117 | ^^^^ 118 119error: diagnostic slug must be first argument of a `#[label(...)]` attribute 120 --> $DIR/subdiagnostic-derive.rs:226:5 121 | 122LL | #[label(code = "...")] 123 | ^^^^^^^^^^^^^^^^^^^^^^ 124 125error: the `#[primary_span]` attribute can only be applied to fields of type `Span` or `MultiSpan` 126 --> $DIR/subdiagnostic-derive.rs:255:5 127 | 128LL | #[primary_span] 129 | ^^^^^^^^^^^^^^^ 130 131error: label without `#[primary_span]` field 132 --> $DIR/subdiagnostic-derive.rs:252:1 133 | 134LL | / #[label(no_crate_example)] 135LL | | 136LL | | struct W { 137LL | | #[primary_span] 138LL | | 139LL | | span: String, 140LL | | } 141 | |_^ 142 143error: `#[applicability]` is only valid on suggestions 144 --> $DIR/subdiagnostic-derive.rs:265:5 145 | 146LL | #[applicability] 147 | ^^^^^^^^^^^^^^^^ 148 149error: `#[bar]` is not a valid attribute 150 --> $DIR/subdiagnostic-derive.rs:275:5 151 | 152LL | #[bar] 153 | ^^^^^^ 154 | 155 = help: only `primary_span`, `applicability` and `skip_arg` are valid field attributes 156 157error: `#[bar = ...]` is not a valid attribute 158 --> $DIR/subdiagnostic-derive.rs:286:5 159 | 160LL | #[bar = "..."] 161 | ^^^^^^^^^^^^^^ 162 163error: `#[bar(...)]` is not a valid attribute 164 --> $DIR/subdiagnostic-derive.rs:297:5 165 | 166LL | #[bar("...")] 167 | ^^^^^^^^^^^^^ 168 | 169 = help: only `primary_span`, `applicability` and `skip_arg` are valid field attributes 170 171error: a diagnostic slug must be the first argument to the attribute 172 --> $DIR/subdiagnostic-derive.rs:329:44 173 | 174LL | #[label(no_crate_example, no_crate::example)] 175 | ^ 176 177error: specified multiple times 178 --> $DIR/subdiagnostic-derive.rs:342:5 179 | 180LL | #[primary_span] 181 | ^^^^^^^^^^^^^^^ 182 | 183note: previously specified here 184 --> $DIR/subdiagnostic-derive.rs:339:5 185 | 186LL | #[primary_span] 187 | ^^^^^^^^^^^^^^^ 188 189error: subdiagnostic kind not specified 190 --> $DIR/subdiagnostic-derive.rs:348:8 191 | 192LL | struct AG { 193 | ^^ 194 195error: specified multiple times 196 --> $DIR/subdiagnostic-derive.rs:385:46 197 | 198LL | #[suggestion(no_crate_example, code = "...", code = "...")] 199 | ^^^^ 200 | 201note: previously specified here 202 --> $DIR/subdiagnostic-derive.rs:385:32 203 | 204LL | #[suggestion(no_crate_example, code = "...", code = "...")] 205 | ^^^^ 206 207error: specified multiple times 208 --> $DIR/subdiagnostic-derive.rs:403:5 209 | 210LL | #[applicability] 211 | ^^^^^^^^^^^^^^^^ 212 | 213note: previously specified here 214 --> $DIR/subdiagnostic-derive.rs:400:5 215 | 216LL | #[applicability] 217 | ^^^^^^^^^^^^^^^^ 218 219error: the `#[applicability]` attribute can only be applied to fields of type `Applicability` 220 --> $DIR/subdiagnostic-derive.rs:413:5 221 | 222LL | #[applicability] 223 | ^^^^^^^^^^^^^^^^ 224 225error: suggestion without `code = "..."` 226 --> $DIR/subdiagnostic-derive.rs:426:1 227 | 228LL | #[suggestion(no_crate_example)] 229 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 230 231error: invalid applicability 232 --> $DIR/subdiagnostic-derive.rs:436:62 233 | 234LL | #[suggestion(no_crate_example, code = "...", applicability = "foo")] 235 | ^^^^^ 236 237error: suggestion without `#[primary_span]` field 238 --> $DIR/subdiagnostic-derive.rs:454:1 239 | 240LL | / #[suggestion(no_crate_example, code = "...")] 241LL | | 242LL | | struct AR { 243LL | | var: String, 244LL | | } 245 | |_^ 246 247error: unsupported type attribute for subdiagnostic enum 248 --> $DIR/subdiagnostic-derive.rs:468:1 249 | 250LL | #[label] 251 | ^^^^^^^^ 252 253error: `var` doesn't refer to a field on this type 254 --> $DIR/subdiagnostic-derive.rs:488:39 255 | 256LL | #[suggestion(no_crate_example, code = "{var}", applicability = "machine-applicable")] 257 | ^^^^^^^ 258 259error: `var` doesn't refer to a field on this type 260 --> $DIR/subdiagnostic-derive.rs:507:43 261 | 262LL | #[suggestion(no_crate_example, code = "{var}", applicability = "machine-applicable")] 263 | ^^^^^^^ 264 265error: `#[suggestion_part]` is not a valid attribute 266 --> $DIR/subdiagnostic-derive.rs:530:5 267 | 268LL | #[suggestion_part] 269 | ^^^^^^^^^^^^^^^^^^ 270 | 271 = help: `#[suggestion_part(...)]` is only valid in multipart suggestions, use `#[primary_span]` instead 272 273error: `#[suggestion_part(...)]` is not a valid attribute 274 --> $DIR/subdiagnostic-derive.rs:533:5 275 | 276LL | #[suggestion_part(code = "...")] 277 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 278 | 279 = help: `#[suggestion_part(...)]` is only valid in multipart suggestions 280 281error: suggestion without `#[primary_span]` field 282 --> $DIR/subdiagnostic-derive.rs:527:1 283 | 284LL | / #[suggestion(no_crate_example, code = "...")] 285LL | | 286LL | | struct BA { 287LL | | #[suggestion_part] 288... | 289LL | | var: String, 290LL | | } 291 | |_^ 292 293error: invalid nested attribute 294 --> $DIR/subdiagnostic-derive.rs:542:42 295 | 296LL | #[multipart_suggestion(no_crate_example, code = "...", applicability = "machine-applicable")] 297 | ^^^^ 298 | 299 = help: only `no_span`, `style` and `applicability` are valid nested attributes 300 301error: multipart suggestion without any `#[suggestion_part(...)]` fields 302 --> $DIR/subdiagnostic-derive.rs:542:1 303 | 304LL | / #[multipart_suggestion(no_crate_example, code = "...", applicability = "machine-applicable")] 305LL | | 306LL | | 307LL | | struct BBa { 308LL | | var: String, 309LL | | } 310 | |_^ 311 312error: `#[suggestion_part(...)]` attribute without `code = "..."` 313 --> $DIR/subdiagnostic-derive.rs:552:5 314 | 315LL | #[suggestion_part] 316 | ^^^^^^^^^^^^^^^^^^ 317 318error: `#[suggestion_part(...)]` attribute without `code = "..."` 319 --> $DIR/subdiagnostic-derive.rs:560:5 320 | 321LL | #[suggestion_part()] 322 | ^^^^^^^^^^^^^^^^^^^^ 323 324error: `#[primary_span]` is not a valid attribute 325 --> $DIR/subdiagnostic-derive.rs:569:5 326 | 327LL | #[primary_span] 328 | ^^^^^^^^^^^^^^^ 329 | 330 = help: multipart suggestions use one or more `#[suggestion_part]`s rather than one `#[primary_span]` 331 332error: multipart suggestion without any `#[suggestion_part(...)]` fields 333 --> $DIR/subdiagnostic-derive.rs:566:1 334 | 335LL | / #[multipart_suggestion(no_crate_example)] 336LL | | 337LL | | struct BC { 338LL | | #[primary_span] 339LL | | 340LL | | span: Span, 341LL | | } 342 | |_^ 343 344error: `#[suggestion_part(...)]` attribute without `code = "..."` 345 --> $DIR/subdiagnostic-derive.rs:577:5 346 | 347LL | #[suggestion_part] 348 | ^^^^^^^^^^^^^^^^^^ 349 350error: `#[suggestion_part(...)]` attribute without `code = "..."` 351 --> $DIR/subdiagnostic-derive.rs:580:5 352 | 353LL | #[suggestion_part()] 354 | ^^^^^^^^^^^^^^^^^^^^ 355 356error: `code` is the only valid nested attribute 357 --> $DIR/subdiagnostic-derive.rs:583:23 358 | 359LL | #[suggestion_part(foo = "bar")] 360 | ^^^ 361 362error: the `#[suggestion_part(...)]` attribute can only be applied to fields of type `Span` or `MultiSpan` 363 --> $DIR/subdiagnostic-derive.rs:588:5 364 | 365LL | #[suggestion_part(code = "...")] 366 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 367 368error: the `#[suggestion_part(...)]` attribute can only be applied to fields of type `Span` or `MultiSpan` 369 --> $DIR/subdiagnostic-derive.rs:591:5 370 | 371LL | #[suggestion_part()] 372 | ^^^^^^^^^^^^^^^^^^^^ 373 374error: specified multiple times 375 --> $DIR/subdiagnostic-derive.rs:599:37 376 | 377LL | #[suggestion_part(code = "...", code = ",,,")] 378 | ^^^^ 379 | 380note: previously specified here 381 --> $DIR/subdiagnostic-derive.rs:599:23 382 | 383LL | #[suggestion_part(code = "...", code = ",,,")] 384 | ^^^^ 385 386error: `#[applicability]` has no effect if all `#[suggestion]`/`#[multipart_suggestion]` attributes have a static `applicability = "..."` 387 --> $DIR/subdiagnostic-derive.rs:628:5 388 | 389LL | #[applicability] 390 | ^^^^^^^^^^^^^^^^ 391 392error: expected exactly one string literal for `code = ...` 393 --> $DIR/subdiagnostic-derive.rs:676:34 394 | 395LL | #[suggestion_part(code("foo"))] 396 | ^ 397 398error: expected exactly one string literal for `code = ...` 399 --> $DIR/subdiagnostic-derive.rs:687:41 400 | 401LL | #[suggestion_part(code("foo", "bar"))] 402 | ^ 403 404error: expected exactly one string literal for `code = ...` 405 --> $DIR/subdiagnostic-derive.rs:698:30 406 | 407LL | #[suggestion_part(code(3))] 408 | ^ 409 410error: expected exactly one string literal for `code = ...` 411 --> $DIR/subdiagnostic-derive.rs:709:29 412 | 413LL | #[suggestion_part(code())] 414 | ^ 415 416error: specified multiple times 417 --> $DIR/subdiagnostic-derive.rs:764:1 418 | 419LL | #[suggestion(no_crate_example, code = "", style = "hidden", style = "normal")] 420 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 421 | 422note: previously specified here 423 --> $DIR/subdiagnostic-derive.rs:764:1 424 | 425LL | #[suggestion(no_crate_example, code = "", style = "hidden", style = "normal")] 426 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 427 428error: `#[suggestion_hidden(...)]` is not a valid attribute 429 --> $DIR/subdiagnostic-derive.rs:773:1 430 | 431LL | #[suggestion_hidden(no_crate_example, code = "")] 432 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 433 | 434 = help: Use `#[suggestion(..., style = "hidden")]` instead 435 436error: `#[suggestion_hidden(...)]` is not a valid attribute 437 --> $DIR/subdiagnostic-derive.rs:781:1 438 | 439LL | #[suggestion_hidden(no_crate_example, code = "", style = "normal")] 440 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 441 | 442 = help: Use `#[suggestion(..., style = "hidden")]` instead 443 444error: invalid suggestion style 445 --> $DIR/subdiagnostic-derive.rs:789:51 446 | 447LL | #[suggestion(no_crate_example, code = "", style = "foo")] 448 | ^^^^^ 449 | 450 = help: valid styles are `normal`, `short`, `hidden`, `verbose` and `tool-only` 451 452error: expected `= "xxx"` 453 --> $DIR/subdiagnostic-derive.rs:797:49 454 | 455LL | #[suggestion(no_crate_example, code = "", style = 42)] 456 | ^ 457 458error: a diagnostic slug must be the first argument to the attribute 459 --> $DIR/subdiagnostic-derive.rs:805:48 460 | 461LL | #[suggestion(no_crate_example, code = "", style)] 462 | ^ 463 464error: expected `= "xxx"` 465 --> $DIR/subdiagnostic-derive.rs:813:48 466 | 467LL | #[suggestion(no_crate_example, code = "", style("foo"))] 468 | ^ 469 470error: `#[primary_span]` is not a valid attribute 471 --> $DIR/subdiagnostic-derive.rs:826:5 472 | 473LL | #[primary_span] 474 | ^^^^^^^^^^^^^^^ 475 | 476 = note: there must be exactly one primary span 477 = help: to create a suggestion with multiple spans, use `#[multipart_suggestion]` instead 478 479error: suggestion without `#[primary_span]` field 480 --> $DIR/subdiagnostic-derive.rs:823:1 481 | 482LL | / #[suggestion(no_crate_example, code = "")] 483LL | | 484LL | | struct PrimarySpanOnVec { 485LL | | #[primary_span] 486... | 487LL | | sub: Vec<Span>, 488LL | | } 489 | |_^ 490 491error[E0433]: failed to resolve: maybe a missing crate `core`? 492 --> $DIR/subdiagnostic-derive.rs:97:9 493 | 494LL | #[label("...")] 495 | ^^^^^ maybe a missing crate `core`? 496 497error[E0433]: failed to resolve: maybe a missing crate `core`? 498 --> $DIR/subdiagnostic-derive.rs:313:1 499 | 500LL | union AC { 501 | ^^^^^ maybe a missing crate `core`? 502 503error[E0433]: failed to resolve: maybe a missing crate `core`? 504 --> $DIR/subdiagnostic-derive.rs:583:27 505 | 506LL | #[suggestion_part(foo = "bar")] 507 | ^ maybe a missing crate `core`? 508 509error[E0433]: failed to resolve: maybe a missing crate `core`? 510 --> $DIR/subdiagnostic-derive.rs:676:28 511 | 512LL | #[suggestion_part(code("foo"))] 513 | ^^^^^ maybe a missing crate `core`? 514 515error[E0433]: failed to resolve: maybe a missing crate `core`? 516 --> $DIR/subdiagnostic-derive.rs:687:28 517 | 518LL | #[suggestion_part(code("foo", "bar"))] 519 | ^^^^^ maybe a missing crate `core`? 520 521error[E0433]: failed to resolve: maybe a missing crate `core`? 522 --> $DIR/subdiagnostic-derive.rs:698:28 523 | 524LL | #[suggestion_part(code(3))] 525 | ^ maybe a missing crate `core`? 526 527error[E0433]: failed to resolve: maybe a missing crate `core`? 528 --> $DIR/subdiagnostic-derive.rs:721:30 529 | 530LL | #[suggestion_part(code = 3)] 531 | ^ maybe a missing crate `core`? 532 533error[E0433]: failed to resolve: maybe a missing crate `core`? 534 --> $DIR/subdiagnostic-derive.rs:813:48 535 | 536LL | #[suggestion(no_crate_example, code = "", style("foo"))] 537 | ^ maybe a missing crate `core`? 538 539error: cannot find attribute `foo` in this scope 540 --> $DIR/subdiagnostic-derive.rs:68:3 541 | 542LL | #[foo] 543 | ^^^ 544 545error: cannot find attribute `foo` in this scope 546 --> $DIR/subdiagnostic-derive.rs:164:3 547 | 548LL | #[foo] 549 | ^^^ 550 551error: cannot find attribute `bar` in this scope 552 --> $DIR/subdiagnostic-derive.rs:178:7 553 | 554LL | #[bar] 555 | ^^^ 556 557error: cannot find attribute `bar` in this scope 558 --> $DIR/subdiagnostic-derive.rs:190:7 559 | 560LL | #[bar = "..."] 561 | ^^^ 562 563error: cannot find attribute `bar` in this scope 564 --> $DIR/subdiagnostic-derive.rs:202:7 565 | 566LL | #[bar = 4] 567 | ^^^ 568 569error: cannot find attribute `bar` in this scope 570 --> $DIR/subdiagnostic-derive.rs:214:7 571 | 572LL | #[bar("...")] 573 | ^^^ 574 575error: cannot find attribute `bar` in this scope 576 --> $DIR/subdiagnostic-derive.rs:275:7 577 | 578LL | #[bar] 579 | ^^^ 580 581error: cannot find attribute `bar` in this scope 582 --> $DIR/subdiagnostic-derive.rs:286:7 583 | 584LL | #[bar = "..."] 585 | ^^^ 586 587error: cannot find attribute `bar` in this scope 588 --> $DIR/subdiagnostic-derive.rs:297:7 589 | 590LL | #[bar("...")] 591 | ^^^ 592 593error[E0425]: cannot find value `slug` in module `crate::fluent_generated` 594 --> $DIR/subdiagnostic-derive.rs:127:9 595 | 596LL | #[label(slug)] 597 | ^^^^ not found in `crate::fluent_generated` 598 599error[E0425]: cannot find value `__code_29` in this scope 600 --> $DIR/subdiagnostic-derive.rs:715:10 601 | 602LL | #[derive(Subdiagnostic)] 603 | ^^^^^^^^^^^^^ not found in this scope 604 | 605 = note: this error originates in the derive macro `Subdiagnostic` (in Nightly builds, run with -Z macro-backtrace for more info) 606 607error: aborting due to 86 previous errors 608 609Some errors have detailed explanations: E0425, E0433. 610For more information about an error, try `rustc --explain E0425`.