mirror of
https://github.com/astral-sh/ruff.git
synced 2025-08-04 02:38:25 +00:00
red_knot_python_semantic: remove #[must_use]
on diagnostic guard constructor
I believe this was an artifact of an older iteration of the diagnostic reporting API. But this is strictly not necessary now, and indeed, might even be annoying. It is okay, but perhaps looks a little odd, to do `builder.into_diagnostic("...")` if you don't want to add anything else to the diagnostic.
This commit is contained in:
parent
14f71ceb83
commit
3b300559ab
1 changed files with 0 additions and 2 deletions
|
@ -404,7 +404,6 @@ impl<'db, 'ctx> LintDiagnosticGuardBuilder<'db, 'ctx> {
|
|||
///
|
||||
/// The diagnostic can be further mutated on the guard via its `DerefMut`
|
||||
/// impl to `Diagnostic`.
|
||||
#[must_use]
|
||||
pub(super) fn into_diagnostic(
|
||||
self,
|
||||
message: impl std::fmt::Display,
|
||||
|
@ -541,7 +540,6 @@ impl<'db, 'ctx> DiagnosticGuardBuilder<'db, 'ctx> {
|
|||
///
|
||||
/// The diagnostic can be further mutated on the guard via its `DerefMut`
|
||||
/// impl to `Diagnostic`.
|
||||
#[must_use]
|
||||
pub(super) fn into_diagnostic(
|
||||
self,
|
||||
message: impl std::fmt::Display,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue