diff options
| author | bors <bors@rust-lang.org> | 2023-05-10 07:39:31 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2023-05-10 07:39:31 +0000 |
| commit | 7a41eacf170ed234e059608515115e94fbe721fe (patch) | |
| tree | bba0f53fa3cae672594193a410b19c864c12cc5f /compiler/rustc_parse/src/errors.rs | |
| parent | 7fb4332ce452875b0f86dd62be0b1356e6d9537d (diff) | |
| parent | 68c7d2083f315a349caf3202a5495b1c99a38461 (diff) | |
| download | rust-7a41eacf170ed234e059608515115e94fbe721fe.tar.gz rust-7a41eacf170ed234e059608515115e94fbe721fe.zip | |
Auto merge of #2885 - RalfJung:rustup, r=RalfJung
Rustup
Diffstat (limited to 'compiler/rustc_parse/src/errors.rs')
| -rw-r--r-- | compiler/rustc_parse/src/errors.rs | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/compiler/rustc_parse/src/errors.rs b/compiler/rustc_parse/src/errors.rs index 010a13aefa4..b6aeaf3d59f 100644 --- a/compiler/rustc_parse/src/errors.rs +++ b/compiler/rustc_parse/src/errors.rs @@ -907,6 +907,18 @@ pub(crate) struct SuggRemoveComma { } #[derive(Subdiagnostic)] +#[suggestion( + parse_sugg_add_let_for_stmt, + style = "verbose", + applicability = "maybe-incorrect", + code = "let " +)] +pub(crate) struct SuggAddMissingLetStmt { + #[primary_span] + pub span: Span, +} + +#[derive(Subdiagnostic)] pub(crate) enum ExpectedIdentifierFound { #[label(parse_expected_identifier_found_reserved_identifier)] ReservedIdentifier(#[primary_span] Span), @@ -2644,3 +2656,18 @@ pub(crate) struct MalformedCfgAttr { pub span: Span, pub sugg: &'static str, } + +#[derive(Diagnostic)] +#[diag(parse_unknown_builtin_construct)] +pub(crate) struct UnknownBuiltinConstruct { + #[primary_span] + pub span: Span, + pub name: Symbol, +} + +#[derive(Diagnostic)] +#[diag(parse_expected_builtin_ident)] +pub(crate) struct ExpectedBuiltinIdent { + #[primary_span] + pub span: Span, +} |
