From 185bcfef1a84fc822a48690feef2978705fe3eeb Mon Sep 17 00:00:00 2001 From: Andrew Gallant Date: Tue, 1 Apr 2025 15:04:05 -0400 Subject: [PATCH] red_knot_python_semantic: remove comment about `TypeCheckDiagnostic` I put this in its own commit in case all of the information removed here was controversial. But it *looks* stale to me. At the very least, `TypeCheckDiagnostic` no longer exists, so that would need to be fixed. And it doesn't really make sense to me (at this point) to make `Diagnostic` a Salsa struct, particularly since we are keen on using it in Ruff (at some point). --- crates/red_knot_python_semantic/src/types/diagnostic.rs | 6 ------ 1 file changed, 6 deletions(-) diff --git a/crates/red_knot_python_semantic/src/types/diagnostic.rs b/crates/red_knot_python_semantic/src/types/diagnostic.rs index b958f2332b..42fba177dc 100644 --- a/crates/red_knot_python_semantic/src/types/diagnostic.rs +++ b/crates/red_knot_python_semantic/src/types/diagnostic.rs @@ -895,12 +895,6 @@ declare_lint! { } /// A collection of type check diagnostics. -/// -/// The diagnostics are wrapped in an `Arc` because they need to be cloned multiple times -/// when going from `infer_expression` to `check_file`. We could consider -/// making [`TypeCheckDiagnostic`] a Salsa struct to have them Arena-allocated (once the Tables refactor is done). -/// Using Salsa struct does have the downside that it leaks the Salsa dependency into diagnostics and -/// each Salsa-struct comes with an overhead. #[derive(Default, Eq, PartialEq)] pub struct TypeCheckDiagnostics { diagnostics: Vec,