diff options
Diffstat (limited to '')
-rw-r--r-- | src/test/ui-fulldeps/session-diagnostic/subdiagnostic-derive.stderr | 400 |
1 files changed, 400 insertions, 0 deletions
diff --git a/src/test/ui-fulldeps/session-diagnostic/subdiagnostic-derive.stderr b/src/test/ui-fulldeps/session-diagnostic/subdiagnostic-derive.stderr new file mode 100644 index 000000000..a289c4fff --- /dev/null +++ b/src/test/ui-fulldeps/session-diagnostic/subdiagnostic-derive.stderr @@ -0,0 +1,400 @@ +error: label without `#[primary_span]` field + --> $DIR/subdiagnostic-derive.rs:47:1 + | +LL | / #[label(parser::add_paren)] +LL | | +LL | | struct C { +LL | | var: String, +LL | | } + | |_^ + +error: `#[label]` is not a valid attribute + --> $DIR/subdiagnostic-derive.rs:54:1 + | +LL | #[label] + | ^^^^^^^^ + +error: `#[foo]` is not a valid attribute + --> $DIR/subdiagnostic-derive.rs:63:1 + | +LL | #[foo] + | ^^^^^^ + +error: `#[label = ...]` is not a valid attribute + --> $DIR/subdiagnostic-derive.rs:73:1 + | +LL | #[label = "..."] + | ^^^^^^^^^^^^^^^^ + +error: `#[label(bug = ...)]` is not a valid attribute + --> $DIR/subdiagnostic-derive.rs:82:9 + | +LL | #[label(bug = "...")] + | ^^^^^^^^^^^ + | + = help: first argument of the attribute should be the diagnostic slug + +error: `#[label("...")]` is not a valid attribute + --> $DIR/subdiagnostic-derive.rs:91:9 + | +LL | #[label("...")] + | ^^^^^ + | + = help: first argument of the attribute should be the diagnostic slug + +error: `#[label(slug = ...)]` is not a valid attribute + --> $DIR/subdiagnostic-derive.rs:100:9 + | +LL | #[label(slug = 4)] + | ^^^^^^^^ + | + = help: first argument of the attribute should be the diagnostic slug + +error: `#[label(slug(...))]` is not a valid attribute + --> $DIR/subdiagnostic-derive.rs:109:9 + | +LL | #[label(slug("..."))] + | ^^^^^^^^^^^ + | + = help: first argument of the attribute should be the diagnostic slug + +error: diagnostic slug must be first argument of a `#[label(...)]` attribute + --> $DIR/subdiagnostic-derive.rs:128:1 + | +LL | #[label()] + | ^^^^^^^^^^ + +error: `code` is not a valid nested attribute of a `label` attribute + --> $DIR/subdiagnostic-derive.rs:137:1 + | +LL | #[label(parser::add_paren, code = "...")] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +error: `applicability` is not a valid nested attribute of a `label` attribute + --> $DIR/subdiagnostic-derive.rs:146:1 + | +LL | #[label(parser::add_paren, applicability = "machine-applicable")] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +error: unsupported type attribute for subdiagnostic enum + --> $DIR/subdiagnostic-derive.rs:155:1 + | +LL | #[foo] + | ^^^^^^ + +error: `#[bar]` is not a valid attribute + --> $DIR/subdiagnostic-derive.rs:169:5 + | +LL | #[bar] + | ^^^^^^ + +error: `#[bar = ...]` is not a valid attribute + --> $DIR/subdiagnostic-derive.rs:181:5 + | +LL | #[bar = "..."] + | ^^^^^^^^^^^^^^ + +error: `#[bar = ...]` is not a valid attribute + --> $DIR/subdiagnostic-derive.rs:193:5 + | +LL | #[bar = 4] + | ^^^^^^^^^^ + +error: `#[bar("...")]` is not a valid attribute + --> $DIR/subdiagnostic-derive.rs:205:11 + | +LL | #[bar("...")] + | ^^^^^ + | + = help: first argument of the attribute should be the diagnostic slug + +error: diagnostic slug must be first argument of a `#[label(...)]` attribute + --> $DIR/subdiagnostic-derive.rs:217:5 + | +LL | #[label(code = "...")] + | ^^^^^^^^^^^^^^^^^^^^^^ + +error: subdiagnostic kind not specified + --> $DIR/subdiagnostic-derive.rs:234:5 + | +LL | B { + | ^ + +error: the `#[primary_span]` attribute can only be applied to fields of type `Span` or `MultiSpan` + --> $DIR/subdiagnostic-derive.rs:246:5 + | +LL | #[primary_span] + | ^^^^^^^^^^^^^^^ + +error: label without `#[primary_span]` field + --> $DIR/subdiagnostic-derive.rs:243:1 + | +LL | / #[label(parser::add_paren)] +LL | | +LL | | struct W { +LL | | #[primary_span] +LL | | +LL | | span: String, +LL | | } + | |_^ + +error: `#[applicability]` is only valid on suggestions + --> $DIR/subdiagnostic-derive.rs:256:5 + | +LL | #[applicability] + | ^^^^^^^^^^^^^^^^ + +error: `#[bar]` is not a valid attribute + --> $DIR/subdiagnostic-derive.rs:266:5 + | +LL | #[bar] + | ^^^^^^ + | + = help: only `primary_span`, `applicability` and `skip_arg` are valid field attributes + +error: `#[bar = ...]` is not a valid attribute + --> $DIR/subdiagnostic-derive.rs:277:5 + | +LL | #[bar = "..."] + | ^^^^^^^^^^^^^^ + +error: `#[bar(...)]` is not a valid attribute + --> $DIR/subdiagnostic-derive.rs:288:5 + | +LL | #[bar("...")] + | ^^^^^^^^^^^^^ + +error: unexpected unsupported untagged union + --> $DIR/subdiagnostic-derive.rs:304:1 + | +LL | / union AC { +LL | | +LL | | span: u32, +LL | | b: u64 +LL | | } + | |_^ + +error: specified multiple times + --> $DIR/subdiagnostic-derive.rs:314:1 + | +LL | #[label(parser::add_paren)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ + | +note: previously specified here + --> $DIR/subdiagnostic-derive.rs:311:1 + | +LL | #[label(parser::add_paren)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +error: specified multiple times + --> $DIR/subdiagnostic-derive.rs:314:1 + | +LL | #[label(parser::add_paren)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ + | +note: previously specified here + --> $DIR/subdiagnostic-derive.rs:311:1 + | +LL | #[label(parser::add_paren)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +error: `#[label(parser::add_paren)]` is not a valid attribute + --> $DIR/subdiagnostic-derive.rs:323:28 + | +LL | #[label(parser::add_paren, parser::add_paren)] + | ^^^^^^^^^^^^^^^^^ + | + = help: a diagnostic slug must be the first argument to the attribute + +error: specified multiple times + --> $DIR/subdiagnostic-derive.rs:336:5 + | +LL | #[primary_span] + | ^^^^^^^^^^^^^^^ + | +note: previously specified here + --> $DIR/subdiagnostic-derive.rs:333:5 + | +LL | #[primary_span] + | ^^^^^^^^^^^^^^^ + +error: subdiagnostic kind not specified + --> $DIR/subdiagnostic-derive.rs:342:8 + | +LL | struct AG { + | ^^ + +error: specified multiple times + --> $DIR/subdiagnostic-derive.rs:379:47 + | +LL | #[suggestion(parser::add_paren, code = "...", code = "...")] + | ^^^^^^^^^^^^ + | +note: previously specified here + --> $DIR/subdiagnostic-derive.rs:379:33 + | +LL | #[suggestion(parser::add_paren, code = "...", code = "...")] + | ^^^^^^^^^^^^ + +error: specified multiple times + --> $DIR/subdiagnostic-derive.rs:397:5 + | +LL | #[applicability] + | ^^^^^^^^^^^^^^^^ + | +note: previously specified here + --> $DIR/subdiagnostic-derive.rs:394:5 + | +LL | #[applicability] + | ^^^^^^^^^^^^^^^^ + +error: the `#[applicability]` attribute can only be applied to fields of type `Applicability` + --> $DIR/subdiagnostic-derive.rs:408:5 + | +LL | #[applicability] + | ^^^^^^^^^^^^^^^^ + +error: suggestion without `applicability` + --> $DIR/subdiagnostic-derive.rs:403:1 + | +LL | / #[suggestion(parser::add_paren, code = "...")] +LL | | +LL | | struct AL { +LL | | #[primary_span] +... | +LL | | applicability: Span, +LL | | } + | |_^ + +error: suggestion without `applicability` + --> $DIR/subdiagnostic-derive.rs:414:1 + | +LL | / #[suggestion(parser::add_paren, code = "...")] +LL | | +LL | | struct AM { +LL | | #[primary_span] +LL | | span: Span, +LL | | } + | |_^ + +error: suggestion without `code = "..."` + --> $DIR/subdiagnostic-derive.rs:422:1 + | +LL | / #[suggestion(parser::add_paren)] +LL | | +LL | | struct AN { +LL | | #[primary_span] +... | +LL | | applicability: Applicability, +LL | | } + | |_^ + +error: invalid applicability + --> $DIR/subdiagnostic-derive.rs:432:46 + | +LL | #[suggestion(parser::add_paren, code ="...", applicability = "foo")] + | ^^^^^^^^^^^^^^^^^^^^^ + +error: suggestion without `applicability` + --> $DIR/subdiagnostic-derive.rs:450:1 + | +LL | / #[suggestion(parser::add_paren, code = "...")] +LL | | +LL | | +LL | | struct AR { +LL | | var: String, +LL | | } + | |_^ + +error: suggestion without `#[primary_span]` field + --> $DIR/subdiagnostic-derive.rs:450:1 + | +LL | / #[suggestion(parser::add_paren, code = "...")] +LL | | +LL | | +LL | | struct AR { +LL | | var: String, +LL | | } + | |_^ + +error: unsupported type attribute for subdiagnostic enum + --> $DIR/subdiagnostic-derive.rs:465:1 + | +LL | #[label] + | ^^^^^^^^ + +error: `var` doesn't refer to a field on this type + --> $DIR/subdiagnostic-derive.rs:485:39 + | +LL | #[suggestion(parser::add_paren, code ="{var}", applicability = "machine-applicable")] + | ^^^^^^^ + +error: `var` doesn't refer to a field on this type + --> $DIR/subdiagnostic-derive.rs:504:43 + | +LL | #[suggestion(parser::add_paren, code ="{var}", applicability = "machine-applicable")] + | ^^^^^^^ + +error: cannot find attribute `foo` in this scope + --> $DIR/subdiagnostic-derive.rs:63:3 + | +LL | #[foo] + | ^^^ + +error: cannot find attribute `foo` in this scope + --> $DIR/subdiagnostic-derive.rs:155:3 + | +LL | #[foo] + | ^^^ + +error: cannot find attribute `bar` in this scope + --> $DIR/subdiagnostic-derive.rs:169:7 + | +LL | #[bar] + | ^^^ + +error: cannot find attribute `bar` in this scope + --> $DIR/subdiagnostic-derive.rs:181:7 + | +LL | #[bar = "..."] + | ^^^ + +error: cannot find attribute `bar` in this scope + --> $DIR/subdiagnostic-derive.rs:193:7 + | +LL | #[bar = 4] + | ^^^ + +error: cannot find attribute `bar` in this scope + --> $DIR/subdiagnostic-derive.rs:205:7 + | +LL | #[bar("...")] + | ^^^ + +error: cannot find attribute `bar` in this scope + --> $DIR/subdiagnostic-derive.rs:266:7 + | +LL | #[bar] + | ^^^ + +error: cannot find attribute `bar` in this scope + --> $DIR/subdiagnostic-derive.rs:277:7 + | +LL | #[bar = "..."] + | ^^^ + +error: cannot find attribute `bar` in this scope + --> $DIR/subdiagnostic-derive.rs:288:7 + | +LL | #[bar("...")] + | ^^^ + +error[E0425]: cannot find value `slug` in module `rustc_errors::fluent` + --> $DIR/subdiagnostic-derive.rs:118:9 + | +LL | #[label(slug)] + | ^^^^ not found in `rustc_errors::fluent` + +error: aborting due to 52 previous errors + +For more information about this error, try `rustc --explain E0425`. |