refactor: remove once_cell use from tinymist (#1632)

* refactor: remove `once_cell` use from tinymist

* feat: remove more
This commit is contained in:
Myriad-Dreamin 2025-04-08 02:11:44 +08:00 committed by GitHub
parent 769fc93df9
commit 72e33e461d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
20 changed files with 68 additions and 82 deletions

View file

@ -5,7 +5,6 @@ use typst::syntax::Span;
use crate::{prelude::*, LspWorldExt};
use once_cell::sync::Lazy;
use regex::RegexSet;
/// Stores diagnostics for files.
@ -198,7 +197,7 @@ trait DiagnosticRefiner {
struct DeprecationRefiner<const MINOR: usize>();
static DEPRECATION_PATTERNS: Lazy<RegexSet> = Lazy::new(|| {
static DEPRECATION_PATTERNS: LazyLock<RegexSet> = LazyLock::new(|| {
RegexSet::new([
r"unknown variable: style",
r"unexpected argument: fill",