Converts this collection to one that accepts any severity type. This is useful when you need to combine diagnostics with different severity type parameters into a single collection. # Examples ``` use hashql_diagnostics::{Diagnostic, DiagnosticIssues, Label, Severity}; # use hashql_diagnostics::category::TerminalDiagnosticCategory; # const CATEGORY: TerminalDiagnosticCategory = TerminalDiagnost
(self)
| 613 | /// assert_eq!(general_issues.critical(), 1); |
| 614 | /// ``` |
| 615 | pub fn generalize(self) -> DiagnosticIssues<C, S, Severity> { |
| 616 | DiagnosticIssues { |
| 617 | diagnostics: self |
| 618 | .diagnostics |
| 619 | .into_iter() |
| 620 | .map(Diagnostic::generalize) |
| 621 | .collect(), |
| 622 | critical: self.critical, |
| 623 | } |
| 624 | } |
| 625 | |
| 626 | #[must_use] |
| 627 | pub fn into_vec(self) -> Vec<Diagnostic<C, S, K>> { |
no test coverage detected