diff options
| author | Michael Goulet <michael@errs.io> | 2024-08-21 00:57:58 -0400 |
|---|---|---|
| committer | Michael Goulet <michael@errs.io> | 2024-08-21 01:31:11 -0400 |
| commit | 25ff9b6bcbba9e7831eb4d6eba2df6bbcd267c55 (patch) | |
| tree | 7c081b337e865ac7a20217d90e29a14ce63dcef0 /compiler/rustc_lint/src/lints.rs | |
| parent | 4d5b3b196284aded6ae99d12bcf149ffdc8ef379 (diff) | |
| download | rust-25ff9b6bcbba9e7831eb4d6eba2df6bbcd267c55.tar.gz rust-25ff9b6bcbba9e7831eb4d6eba2df6bbcd267c55.zip | |
Use bool in favor of Option<()> for diagnostics
Diffstat (limited to 'compiler/rustc_lint/src/lints.rs')
| -rw-r--r-- | compiler/rustc_lint/src/lints.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/compiler/rustc_lint/src/lints.rs b/compiler/rustc_lint/src/lints.rs index 03962d796f4..c12c5427997 100644 --- a/compiler/rustc_lint/src/lints.rs +++ b/compiler/rustc_lint/src/lints.rs @@ -257,7 +257,7 @@ pub struct BuiltinUnreachablePub<'a> { #[suggestion(code = "pub(crate)")] pub suggestion: (Span, Applicability), #[help] - pub help: Option<()>, + pub help: bool, } #[derive(LintDiagnostic)] @@ -572,7 +572,7 @@ pub struct Expectation { #[subdiagnostic] pub rationale: Option<ExpectationNote>, #[note] - pub note: Option<()>, + pub note: bool, } #[derive(Subdiagnostic)] @@ -756,7 +756,7 @@ pub enum InvalidReferenceCastingDiag<'tcx> { #[label] orig_cast: Option<Span>, #[note(lint_invalid_reference_casting_note_ty_has_interior_mutability)] - ty_has_interior_mutability: Option<()>, + ty_has_interior_mutability: bool, }, #[diag(lint_invalid_reference_casting_assign_to_ref)] #[note(lint_invalid_reference_casting_note_book)] @@ -764,7 +764,7 @@ pub enum InvalidReferenceCastingDiag<'tcx> { #[label] orig_cast: Option<Span>, #[note(lint_invalid_reference_casting_note_ty_has_interior_mutability)] - ty_has_interior_mutability: Option<()>, + ty_has_interior_mutability: bool, }, #[diag(lint_invalid_reference_casting_bigger_layout)] #[note(lint_layout)] |
