Skip to content

Commit

Permalink
Lrc
Browse files Browse the repository at this point in the history
  • Loading branch information
kdy1 committed Jan 26, 2025
1 parent b96f61d commit 9b38e17
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 7 deletions.
2 changes: 1 addition & 1 deletion crates/swc_ecma_transforms_react/src/jsx/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ pub struct Options {

macro_rules! static_str {
($s:expr) => {{
static VAL: Lazy<Arc<String>> = Lazy::new(|| Arc::new($s.into()));
static VAL: Lazy<Lrc<String>> = Lazy::new(|| Lrc::new($s.into()));
VAL.clone()
}};
}
Expand Down
7 changes: 3 additions & 4 deletions crates/swc_ecma_transforms_typescript/src/config.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
use std::sync::Arc;

use serde::{Deserialize, Serialize};
use swc_common::sync::Lrc;

#[derive(Debug, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
Expand Down Expand Up @@ -41,11 +40,11 @@ pub struct Config {
pub struct TsxConfig {
/// Note: this pass handle jsx directives in comments
#[serde(default)]
pub pragma: Option<Arc<String>>,
pub pragma: Option<Lrc<String>>,

/// Note: this pass handle jsx directives in comments
#[serde(default)]
pub pragma_frag: Option<Arc<String>>,
pub pragma_frag: Option<Lrc<String>>,
}

#[derive(Default, Clone, Copy, Debug, PartialEq, Eq, Serialize, Deserialize)]
Expand Down
4 changes: 2 additions & 2 deletions crates/swc_ecma_transforms_typescript/src/typescript.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use std::{mem, sync::Arc};
use std::mem;

use once_cell::sync::Lazy;
use swc_common::{
Expand All @@ -14,7 +14,7 @@ use crate::{strip_import_export::StripImportExport, strip_type::StripType, trans

macro_rules! static_str {
($s:expr) => {{
static VAL: Lazy<Arc<String>> = Lazy::new(|| Arc::new($s.into()));
static VAL: Lazy<Lrc<String>> = Lazy::new(|| Lrc::new($s.into()));
VAL.clone()
}};
}
Expand Down

0 comments on commit 9b38e17

Please sign in to comment.