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

@ -8,7 +8,6 @@ use std::{
path::{Path, PathBuf},
};
use once_cell::sync::Lazy;
use serde_json::{ser::PrettyFormatter, Serializer, Value};
use tinymist_project::{CompileFontArgs, ExportTarget, LspCompileSnapshot, LspComputeGraph};
use tinymist_std::path::unix_slash;
@ -353,7 +352,7 @@ pub fn make_range_annoation(source: &Source) -> String {
// pub static REDACT_URI: Lazy<RedactFields> = Lazy::new(||
// RedactFields::from_iter(["uri"]));
pub static REDACT_LOC: Lazy<RedactFields> = Lazy::new(|| {
pub static REDACT_LOC: LazyLock<RedactFields> = LazyLock::new(|| {
RedactFields::from_iter([
"location",
"contents",