From 87c3776271fde26d50a62d014e3b4f47b9f40cc2 Mon Sep 17 00:00:00 2001 From: Nathan Stocks Date: Thu, 18 Aug 2022 16:08:26 -0600 Subject: [PATCH 1/2] fix incorrect #[note] syntax --- src/diagnostics/diagnostic-structs.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/diagnostics/diagnostic-structs.md b/src/diagnostics/diagnostic-structs.md index c197f234e..36ddd615b 100644 --- a/src/diagnostics/diagnostic-structs.md +++ b/src/diagnostics/diagnostic-structs.md @@ -161,7 +161,7 @@ tcx.sess.emit_err(FieldAlreadyDeclared { - See [translation documentation](./translation.md). - `code = "..."` (_Optional_) - Specifies the error code. -- `#[note]` or `#[note = "..."]` (_Optional_) +- `#[note]` or `#[note(...)]` (_Optional_) - _Applied to struct or `Span`/`()` fields._ - Adds a note subdiagnostic. - Value is the Fluent attribute (relative to the Fluent message specified by From c671456fcd3fc47cade503ca38c6f3686d9c25b5 Mon Sep 17 00:00:00 2001 From: Nathan Stocks Date: Thu, 18 Aug 2022 16:31:39 -0600 Subject: [PATCH 2/2] more syntax fixes --- src/diagnostics/diagnostic-structs.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/diagnostics/diagnostic-structs.md b/src/diagnostics/diagnostic-structs.md index 36ddd615b..d30dd180b 100644 --- a/src/diagnostics/diagnostic-structs.md +++ b/src/diagnostics/diagnostic-structs.md @@ -168,14 +168,14 @@ tcx.sess.emit_err(FieldAlreadyDeclared { `slug`) for the note's message - Defaults to `note`. - If applied to a `Span` field, creates a spanned note. -- `#[help]` or `#[help = "..."]` (_Optional_) +- `#[help]` or `#[help(...)]` (_Optional_) - _Applied to struct or `Span`/`()` fields._ - Adds a help subdiagnostic. - Value is the Fluent attribute (relative to the Fluent message specified by `slug`) for the help's message. - Defaults to `help`. - If applied to a `Span` field, creates a spanned help. -- `#[label]` or `#[label = "..."]` (_Optional_) +- `#[label]` or `#[label(...)]` (_Optional_) - _Applied to `Span` fields._ - Adds a label subdiagnostic. - Value is the Fluent attribute (relative to the Fluent message specified by