641 lines
21 KiB
Text
641 lines
21 KiB
Text
error: derive(Diagnostic): unsupported type attribute for diagnostic derive enum
|
|
--> $DIR/diagnostic-derive-inline.rs:44:1
|
|
|
|
|
LL | #[diag("this is an example message", code = E0123)]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): diagnostic message not specified
|
|
--> $DIR/diagnostic-derive-inline.rs:47:5
|
|
|
|
|
LL | Foo,
|
|
| ^^^
|
|
|
|
|
= help: specify the message as the first argument to the `#[diag(...)]` attribute, such as `#[diag("Example error")]`
|
|
|
|
error: derive(Diagnostic): diagnostic message not specified
|
|
--> $DIR/diagnostic-derive-inline.rs:49:5
|
|
|
|
|
LL | Bar,
|
|
| ^^^
|
|
|
|
|
= help: specify the message as the first argument to the `#[diag(...)]` attribute, such as `#[diag("Example error")]`
|
|
|
|
error: expected parentheses: #[diag(...)]
|
|
--> $DIR/diagnostic-derive-inline.rs:55:8
|
|
|
|
|
LL | #[diag = "E0123"]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): `#[nonsense(...)]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:60:1
|
|
|
|
|
LL | #[nonsense("this is an example message", code = E0123)]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): diagnostic message not specified
|
|
--> $DIR/diagnostic-derive-inline.rs:60:1
|
|
|
|
|
LL | #[nonsense("this is an example message", code = E0123)]
|
|
| ^
|
|
|
|
|
= help: specify the message as the first argument to the `#[diag(...)]` attribute, such as `#[diag("Example error")]`
|
|
|
|
error: derive(Diagnostic): diagnostic message not specified
|
|
--> $DIR/diagnostic-derive-inline.rs:67:1
|
|
|
|
|
LL | #[diag(code = E0123)]
|
|
| ^
|
|
|
|
|
= help: specify the message as the first argument to the `#[diag(...)]` attribute, such as `#[diag("Example error")]`
|
|
|
|
error: derive(Diagnostic): diagnostic message not specified
|
|
--> $DIR/diagnostic-derive-inline.rs:72:1
|
|
|
|
|
LL | #[diag(nonsense("foo"), code = E0123, slug = "foo")]
|
|
| ^
|
|
|
|
|
= help: specify the message as the first argument to the `#[diag(...)]` attribute, such as `#[diag("Example error")]`
|
|
|
|
error: derive(Diagnostic): diagnostic message not specified
|
|
--> $DIR/diagnostic-derive-inline.rs:77:1
|
|
|
|
|
LL | #[diag(nonsense = "...", code = E0123, slug = "foo")]
|
|
| ^
|
|
|
|
|
= help: specify the message as the first argument to the `#[diag(...)]` attribute, such as `#[diag("Example error")]`
|
|
|
|
error: derive(Diagnostic): diagnostic message not specified
|
|
--> $DIR/diagnostic-derive-inline.rs:82:1
|
|
|
|
|
LL | #[diag(nonsense = 4, code = E0123, slug = "foo")]
|
|
| ^
|
|
|
|
|
= help: specify the message as the first argument to the `#[diag(...)]` attribute, such as `#[diag("Example error")]`
|
|
|
|
error: derive(Diagnostic): unknown argument
|
|
--> $DIR/diagnostic-derive-inline.rs:87:52
|
|
|
|
|
LL | #[diag("this is an example message", code = E0123, slug = "foo")]
|
|
| ^^^^
|
|
|
|
|
= note: only the `code` parameter is valid after the message
|
|
|
|
error: derive(Diagnostic): `#[suggestion = ...]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:94:5
|
|
|
|
|
LL | #[suggestion = "bar"]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): attribute specified multiple times
|
|
--> $DIR/diagnostic-derive-inline.rs:101:38
|
|
|
|
|
LL | #[diag("this is an example message", code = E0456)]
|
|
| ^^^^
|
|
|
|
|
note: previously specified here
|
|
--> $DIR/diagnostic-derive-inline.rs:100:38
|
|
|
|
|
LL | #[diag("this is an example message", code = E0123)]
|
|
| ^^^^
|
|
|
|
error: derive(Diagnostic): attribute specified multiple times
|
|
--> $DIR/diagnostic-derive-inline.rs:106:52
|
|
|
|
|
LL | #[diag("this is an example message", code = E0123, code = E0456)]
|
|
| ^^^^
|
|
|
|
|
note: previously specified here
|
|
--> $DIR/diagnostic-derive-inline.rs:106:38
|
|
|
|
|
LL | #[diag("this is an example message", code = E0123, code = E0456)]
|
|
| ^^^^
|
|
|
|
error: derive(Diagnostic): diagnostic message must be the first argument
|
|
--> $DIR/diagnostic-derive-inline.rs:111:38
|
|
|
|
|
LL | #[diag("this is an example message", no_crate::example, code = E0123)]
|
|
| ^^^^^^^^
|
|
|
|
error: derive(Diagnostic): diagnostic message not specified
|
|
--> $DIR/diagnostic-derive-inline.rs:116:1
|
|
|
|
|
LL | struct KindNotProvided {}
|
|
| ^^^^^^
|
|
|
|
|
= help: specify the message as the first argument to the `#[diag(...)]` attribute, such as `#[diag("Example error")]`
|
|
|
|
error: derive(Diagnostic): diagnostic message not specified
|
|
--> $DIR/diagnostic-derive-inline.rs:119:1
|
|
|
|
|
LL | #[diag(code = E0123)]
|
|
| ^
|
|
|
|
|
= help: specify the message as the first argument to the `#[diag(...)]` attribute, such as `#[diag("Example error")]`
|
|
|
|
error: derive(Diagnostic): the `#[primary_span]` attribute can only be applied to fields of type `Span` or `MultiSpan`
|
|
--> $DIR/diagnostic-derive-inline.rs:130:5
|
|
|
|
|
LL | #[primary_span]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): `#[nonsense]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:138:5
|
|
|
|
|
LL | #[nonsense]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): the `#[label(...)]` attribute can only be applied to fields of type `Span` or `MultiSpan`
|
|
--> $DIR/diagnostic-derive-inline.rs:155:5
|
|
|
|
|
LL | #[label("with a label")]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): `name` doesn't refer to a field on this type
|
|
--> $DIR/diagnostic-derive-inline.rs:163:46
|
|
|
|
|
LL | #[suggestion("with a suggestion", code = "{name}")]
|
|
| ^^^^^^^^
|
|
|
|
error: invalid format string: expected `}` but string was terminated
|
|
--> $DIR/diagnostic-derive-inline.rs:168:10
|
|
|
|
|
LL | #[derive(Diagnostic)]
|
|
| ^^^^^^^^^^ expected `}` in format string
|
|
|
|
|
= note: if you intended to print `{`, you can escape it using `{{`
|
|
= note: this error originates in the derive macro `Diagnostic` (in Nightly builds, run with -Z macro-backtrace for more info)
|
|
|
|
error: invalid format string: unmatched `}` found
|
|
--> $DIR/diagnostic-derive-inline.rs:178:10
|
|
|
|
|
LL | #[derive(Diagnostic)]
|
|
| ^^^^^^^^^^ unmatched `}` in format string
|
|
|
|
|
= note: if you intended to print `}`, you can escape it using `}}`
|
|
= note: this error originates in the derive macro `Diagnostic` (in Nightly builds, run with -Z macro-backtrace for more info)
|
|
|
|
error: derive(Diagnostic): the `#[label(...)]` attribute can only be applied to fields of type `Span` or `MultiSpan`
|
|
--> $DIR/diagnostic-derive-inline.rs:198:5
|
|
|
|
|
LL | #[label("with a label")]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): suggestion without `code = "..."`
|
|
--> $DIR/diagnostic-derive-inline.rs:217:5
|
|
|
|
|
LL | #[suggestion("with a suggestion")]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): invalid nested attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:225:39
|
|
|
|
|
LL | #[suggestion("with a suggestion", nonsense = "bar")]
|
|
| ^^^^^^^^
|
|
|
|
|
= help: only `style`, `code` and `applicability` are valid nested attributes
|
|
|
|
error: derive(Diagnostic): suggestion without `code = "..."`
|
|
--> $DIR/diagnostic-derive-inline.rs:225:5
|
|
|
|
|
LL | #[suggestion("with a suggestion", nonsense = "bar")]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): invalid nested attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:234:39
|
|
|
|
|
LL | #[suggestion("with a suggestion", msg = "bar")]
|
|
| ^^^
|
|
|
|
|
= help: only `style`, `code` and `applicability` are valid nested attributes
|
|
|
|
error: derive(Diagnostic): suggestion without `code = "..."`
|
|
--> $DIR/diagnostic-derive-inline.rs:234:5
|
|
|
|
|
LL | #[suggestion("with a suggestion", msg = "bar")]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): wrong field type for suggestion
|
|
--> $DIR/diagnostic-derive-inline.rs:257:5
|
|
|
|
|
LL | #[suggestion("with a suggestion", code = "This is suggested code")]
|
|
| ^
|
|
|
|
|
= help: `#[suggestion(...)]` should be applied to fields of type `Span` or `(Span, Applicability)`
|
|
|
|
error: derive(Diagnostic): attribute specified multiple times
|
|
--> $DIR/diagnostic-derive-inline.rs:273:24
|
|
|
|
|
LL | suggestion: (Span, Span, Applicability),
|
|
| ^^^^
|
|
|
|
|
note: previously specified here
|
|
--> $DIR/diagnostic-derive-inline.rs:273:18
|
|
|
|
|
LL | suggestion: (Span, Span, Applicability),
|
|
| ^^^^
|
|
|
|
error: derive(Diagnostic): attribute specified multiple times
|
|
--> $DIR/diagnostic-derive-inline.rs:281:33
|
|
|
|
|
LL | suggestion: (Applicability, Applicability, Span),
|
|
| ^^^^^^^^^^^^^
|
|
|
|
|
note: previously specified here
|
|
--> $DIR/diagnostic-derive-inline.rs:281:18
|
|
|
|
|
LL | suggestion: (Applicability, Applicability, Span),
|
|
| ^^^^^^^^^^^^^
|
|
|
|
error: derive(Diagnostic): `#[label = ...]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:288:5
|
|
|
|
|
LL | #[label = "bar"]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): attribute specified multiple times
|
|
--> $DIR/diagnostic-derive-inline.rs:389:5
|
|
|
|
|
LL | #[suggestion("with a suggestion", code = "...", applicability = "maybe-incorrect")]
|
|
| ^
|
|
|
|
|
note: previously specified here
|
|
--> $DIR/diagnostic-derive-inline.rs:391:24
|
|
|
|
|
LL | suggestion: (Span, Applicability),
|
|
| ^^^^^^^^^^^^^
|
|
|
|
error: derive(Diagnostic): invalid applicability
|
|
--> $DIR/diagnostic-derive-inline.rs:397:69
|
|
|
|
|
LL | #[suggestion("with a suggestion", code = "...", applicability = "batman")]
|
|
| ^^^^^^^^
|
|
|
|
error: derive(Diagnostic): the `#[help(...)]` attribute can only be applied to fields of type `Span`, `MultiSpan`, `bool` or `()`
|
|
--> $DIR/diagnostic-derive-inline.rs:460:5
|
|
|
|
|
LL | #[help("with a help")]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): no nested attribute expected here
|
|
--> $DIR/diagnostic-derive-inline.rs:469:29
|
|
|
|
|
LL | #[label("with a label", foo)]
|
|
| ^^^
|
|
|
|
error: derive(Diagnostic): a diagnostic message must be the first argument to the attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:477:29
|
|
|
|
|
LL | #[label("with a label", "and another one?")]
|
|
| ^^^^^^^^^^^^^^^^^^
|
|
|
|
error: derive(Diagnostic): no nested attribute expected here
|
|
--> $DIR/diagnostic-derive-inline.rs:485:29
|
|
|
|
|
LL | #[label("with a label", foo = "...")]
|
|
| ^^^
|
|
|
|
error: derive(Diagnostic): no nested attribute expected here
|
|
--> $DIR/diagnostic-derive-inline.rs:493:29
|
|
|
|
|
LL | #[label("with a label", foo("..."))]
|
|
| ^^^
|
|
|
|
error: derive(Diagnostic): `#[primary_span]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:505:5
|
|
|
|
|
LL | #[primary_span]
|
|
| ^
|
|
|
|
|
= help: the `primary_span` field attribute is not valid for lint diagnostics
|
|
|
|
error: derive(Diagnostic): `#[error(...)]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:525:1
|
|
|
|
|
LL | #[error("this is an example message", code = E0123)]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): diagnostic message not specified
|
|
--> $DIR/diagnostic-derive-inline.rs:525:1
|
|
|
|
|
LL | #[error("this is an example message", code = E0123)]
|
|
| ^
|
|
|
|
|
= help: specify the message as the first argument to the `#[diag(...)]` attribute, such as `#[diag("Example error")]`
|
|
|
|
error: derive(Diagnostic): `#[warn_(...)]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:532:1
|
|
|
|
|
LL | #[warn_("this is an example message", code = E0123)]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): diagnostic message not specified
|
|
--> $DIR/diagnostic-derive-inline.rs:532:1
|
|
|
|
|
LL | #[warn_("this is an example message", code = E0123)]
|
|
| ^
|
|
|
|
|
= help: specify the message as the first argument to the `#[diag(...)]` attribute, such as `#[diag("Example error")]`
|
|
|
|
error: derive(Diagnostic): `#[lint(...)]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:539:1
|
|
|
|
|
LL | #[lint("this is an example message", code = E0123)]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): diagnostic message not specified
|
|
--> $DIR/diagnostic-derive-inline.rs:539:1
|
|
|
|
|
LL | #[lint("this is an example message", code = E0123)]
|
|
| ^
|
|
|
|
|
= help: specify the message as the first argument to the `#[diag(...)]` attribute, such as `#[diag("Example error")]`
|
|
|
|
error: derive(Diagnostic): `#[lint(...)]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:546:1
|
|
|
|
|
LL | #[lint("this is an example message", code = E0123)]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): diagnostic message not specified
|
|
--> $DIR/diagnostic-derive-inline.rs:546:1
|
|
|
|
|
LL | #[lint("this is an example message", code = E0123)]
|
|
| ^
|
|
|
|
|
= help: specify the message as the first argument to the `#[diag(...)]` attribute, such as `#[diag("Example error")]`
|
|
|
|
error: derive(Diagnostic): attribute specified multiple times
|
|
--> $DIR/diagnostic-derive-inline.rs:555:53
|
|
|
|
|
LL | #[suggestion("with a suggestion", code = "...", code = ",,,")]
|
|
| ^^^^
|
|
|
|
|
note: previously specified here
|
|
--> $DIR/diagnostic-derive-inline.rs:555:39
|
|
|
|
|
LL | #[suggestion("with a suggestion", code = "...", code = ",,,")]
|
|
| ^^^^
|
|
|
|
error: derive(Diagnostic): wrong types for suggestion
|
|
--> $DIR/diagnostic-derive-inline.rs:564:24
|
|
|
|
|
LL | suggestion: (Span, usize),
|
|
| ^^^^^
|
|
|
|
|
= help: `#[suggestion(...)]` on a tuple field must be applied to fields of type `(Span, Applicability)`
|
|
|
|
error: derive(Diagnostic): wrong types for suggestion
|
|
--> $DIR/diagnostic-derive-inline.rs:572:17
|
|
|
|
|
LL | suggestion: (Span,),
|
|
| ^^^^^^^
|
|
|
|
|
= help: `#[suggestion(...)]` on a tuple field must be applied to fields of type `(Span, Applicability)`
|
|
|
|
error: derive(Diagnostic): suggestion without `code = "..."`
|
|
--> $DIR/diagnostic-derive-inline.rs:579:5
|
|
|
|
|
LL | #[suggestion("with a suggestion")]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): `#[multipart_suggestion(...)]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:586:1
|
|
|
|
|
LL | #[multipart_suggestion("with a suggestion")]
|
|
| ^
|
|
|
|
|
= help: consider creating a `Subdiagnostic` instead
|
|
|
|
error: derive(Diagnostic): `#[multipart_suggestion(...)]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:589:1
|
|
|
|
|
LL | #[multipart_suggestion()]
|
|
| ^
|
|
|
|
|
= help: consider creating a `Subdiagnostic` instead
|
|
|
|
error: derive(Diagnostic): `#[multipart_suggestion(...)]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:593:5
|
|
|
|
|
LL | #[multipart_suggestion("with a suggestion")]
|
|
| ^
|
|
|
|
|
= help: consider creating a `Subdiagnostic` instead
|
|
|
|
error: derive(Diagnostic): `#[suggestion(...)]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:601:1
|
|
|
|
|
LL | #[suggestion("with a suggestion", code = "...")]
|
|
| ^
|
|
|
|
|
= help: `#[label]` and `#[suggestion]` can only be applied to fields
|
|
|
|
error: derive(Diagnostic): `#[label]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:610:1
|
|
|
|
|
LL | #[label]
|
|
| ^
|
|
|
|
|
= help: subdiagnostic message is missing
|
|
|
|
error: derive(Diagnostic): `#[subdiagnostic(...)]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:644:5
|
|
|
|
|
LL | #[subdiagnostic(bad)]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): `#[subdiagnostic = ...]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:652:5
|
|
|
|
|
LL | #[subdiagnostic = "bad"]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): `#[subdiagnostic(...)]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:660:5
|
|
|
|
|
LL | #[subdiagnostic(bad, bad)]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): `#[subdiagnostic(...)]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:668:5
|
|
|
|
|
LL | #[subdiagnostic("bad")]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): `#[subdiagnostic(...)]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:676:5
|
|
|
|
|
LL | #[subdiagnostic(eager)]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): `#[subdiagnostic(...)]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:684:5
|
|
|
|
|
LL | #[subdiagnostic(eager)]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): `#[subdiagnostic(...)]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:705:5
|
|
|
|
|
LL | #[subdiagnostic(eager)]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): expected at least one string literal for `code(...)`
|
|
--> $DIR/diagnostic-derive-inline.rs:736:44
|
|
|
|
|
LL | #[suggestion("with a suggestion", code())]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): `code(...)` must contain only string literals
|
|
--> $DIR/diagnostic-derive-inline.rs:744:44
|
|
|
|
|
LL | #[suggestion("with a suggestion", code(foo))]
|
|
| ^^^
|
|
|
|
error: unexpected token, expected `)`
|
|
--> $DIR/diagnostic-derive-inline.rs:744:44
|
|
|
|
|
LL | #[suggestion("with a suggestion", code(foo))]
|
|
| ^^^
|
|
|
|
error: expected string literal
|
|
--> $DIR/diagnostic-derive-inline.rs:753:46
|
|
|
|
|
LL | #[suggestion("with a suggestion", code = 3)]
|
|
| ^
|
|
|
|
error: derive(Diagnostic): `#[suggestion(...)]` is not a valid attribute
|
|
--> $DIR/diagnostic-derive-inline.rs:768:5
|
|
|
|
|
LL | #[suggestion("with a suggestion", code = "")]
|
|
| ^
|
|
|
|
|
= note: `#[suggestion(...)]` applied to `Vec` field is ambiguous
|
|
= help: to show a suggestion consisting of multiple parts, use a `Subdiagnostic` annotated with `#[multipart_suggestion(...)]`
|
|
= help: to show a variable set of suggestions, use a `Vec` of `Subdiagnostic`s annotated with `#[suggestion(...)]`
|
|
|
|
error: derive(Diagnostic): Variable `nosub` not found in diagnostic
|
|
--> $DIR/diagnostic-derive-inline.rs:780:8
|
|
|
|
|
LL | #[diag("does not exist: {$nosub}")]
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
= help: Available fields: "sub"
|
|
|
|
error: cannot find attribute `nonsense` in this scope
|
|
--> $DIR/diagnostic-derive-inline.rs:60:3
|
|
|
|
|
LL | #[nonsense("this is an example message", code = E0123)]
|
|
| ^^^^^^^^
|
|
|
|
error: cannot find attribute `nonsense` in this scope
|
|
--> $DIR/diagnostic-derive-inline.rs:138:7
|
|
|
|
|
LL | #[nonsense]
|
|
| ^^^^^^^^
|
|
|
|
error: cannot find attribute `error` in this scope
|
|
--> $DIR/diagnostic-derive-inline.rs:525:3
|
|
|
|
|
LL | #[error("this is an example message", code = E0123)]
|
|
| ^^^^^
|
|
|
|
|
help: `error` is an attribute that can be used by the derive macro `Error`, you might be missing a `derive` attribute
|
|
|
|
|
LL + #[derive(Error)]
|
|
LL | struct ErrorAttribute {}
|
|
|
|
|
|
|
error: cannot find attribute `warn_` in this scope
|
|
--> $DIR/diagnostic-derive-inline.rs:532:3
|
|
|
|
|
LL | #[warn_("this is an example message", code = E0123)]
|
|
| ^^^^^
|
|
|
|
|
help: a built-in attribute with a similar name exists
|
|
|
|
|
LL - #[warn_("this is an example message", code = E0123)]
|
|
LL + #[warn("this is an example message", code = E0123)]
|
|
|
|
|
|
|
error: cannot find attribute `lint` in this scope
|
|
--> $DIR/diagnostic-derive-inline.rs:539:3
|
|
|
|
|
LL | #[lint("this is an example message", code = E0123)]
|
|
| ^^^^
|
|
|
|
|
help: a built-in attribute with a similar name exists
|
|
|
|
|
LL - #[lint("this is an example message", code = E0123)]
|
|
LL + #[link("this is an example message", code = E0123)]
|
|
|
|
|
|
|
error: cannot find attribute `lint` in this scope
|
|
--> $DIR/diagnostic-derive-inline.rs:546:3
|
|
|
|
|
LL | #[lint("this is an example message", code = E0123)]
|
|
| ^^^^
|
|
|
|
|
help: a built-in attribute with a similar name exists
|
|
|
|
|
LL - #[lint("this is an example message", code = E0123)]
|
|
LL + #[link("this is an example message", code = E0123)]
|
|
|
|
|
|
|
error: cannot find attribute `multipart_suggestion` in this scope
|
|
--> $DIR/diagnostic-derive-inline.rs:586:3
|
|
|
|
|
LL | #[multipart_suggestion("with a suggestion")]
|
|
| ^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
help: `multipart_suggestion` is an attribute that can be used by the derive macro `Subdiagnostic`, you might be missing a `derive` attribute
|
|
|
|
|
LL + #[derive(Subdiagnostic)]
|
|
LL | struct MultipartSuggestion {
|
|
|
|
|
|
|
error: cannot find attribute `multipart_suggestion` in this scope
|
|
--> $DIR/diagnostic-derive-inline.rs:589:3
|
|
|
|
|
LL | #[multipart_suggestion()]
|
|
| ^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
help: `multipart_suggestion` is an attribute that can be used by the derive macro `Subdiagnostic`, you might be missing a `derive` attribute
|
|
|
|
|
LL + #[derive(Subdiagnostic)]
|
|
LL | struct MultipartSuggestion {
|
|
|
|
|
|
|
error: cannot find attribute `multipart_suggestion` in this scope
|
|
--> $DIR/diagnostic-derive-inline.rs:593:7
|
|
|
|
|
LL | #[multipart_suggestion("with a suggestion")]
|
|
| ^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
= note: `multipart_suggestion` is an attribute that can be used by the derive macro `Subdiagnostic`, you might be missing a `derive` attribute
|
|
|
|
error[E0277]: the trait bound `Hello: IntoDiagArg` is not satisfied
|
|
--> $DIR/diagnostic-derive-inline.rs:329:12
|
|
|
|
|
LL | #[derive(Diagnostic)]
|
|
| ---------- required by a bound introduced by this call
|
|
...
|
|
LL | other: Hello,
|
|
| ^^^^^ unsatisfied trait bound
|
|
|
|
|
help: the nightly-only, unstable trait `IntoDiagArg` is not implemented for `Hello`
|
|
--> $DIR/diagnostic-derive-inline.rs:41:1
|
|
|
|
|
LL | struct Hello {}
|
|
| ^^^^^^^^^^^^
|
|
= help: normalized in stderr
|
|
note: required by a bound in `Diag::<'a, G>::arg`
|
|
--> $COMPILER_DIR/rustc_errors/src/diagnostic.rs:LL:CC
|
|
::: $COMPILER_DIR/rustc_errors/src/diagnostic.rs:LL:CC
|
|
|
|
|
= note: in this macro invocation
|
|
= note: this error originates in the macro `with_fn` (in Nightly builds, run with -Z macro-backtrace for more info)
|
|
|
|
error: aborting due to 81 previous errors
|
|
|
|
For more information about this error, try `rustc --explain E0277`.
|