Skip to content

Commit b4db90d

Browse files
committed
chore(es/parser): use stacker in commons
1 parent 1298e76 commit b4db90d

File tree

30 files changed

+134
-160
lines changed

30 files changed

+134
-160
lines changed

.github/workflows/CI.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,7 @@ jobs:
308308
- name: Run cargo test (transforms with stacker)
309309
if: matrix.settings.crate == 'swc_ecma_transforms'
310310
run: |
311-
cargo test -p ${{ matrix.settings.crate }} --all-features --features swc_ecma_utils/stacker
311+
cargo test -p ${{ matrix.settings.crate }} --all-features --features swc_common/stacker
312312
313313
- name: Run cargo test (concurrent)
314314
if: runner.os == 'Linux' && matrix.settings.crate != 'swc_ecma_minifier'

Cargo.lock

Lines changed: 1 addition & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

crates/swc_common/Cargo.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,8 @@ swc_atoms = { version = "5.0.0", path = "../swc_atoms" }
6868
swc_eq_ignore_macros = { version = "1.0.0", path = "../swc_eq_ignore_macros" }
6969
swc_visit = { version = "2.0.0", path = "../swc_visit" }
7070

71+
[target.'cfg(not(any(target_arch = "wasm32", target_arch = "arm")))'.dependencies]
72+
stacker = { version = "0.1.15", optional = true }
7173

7274
[dev-dependencies]
7375
codspeed-criterion-compat = { workspace = true }

crates/swc_common/src/lib.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ pub mod private;
6767
mod rustc_data_structures;
6868
pub mod serializer;
6969
pub mod source_map;
70+
pub mod stack_size;
7071
pub mod sync;
7172
mod syntax_pos;
7273
pub mod util;
File renamed without changes.

crates/swc_core/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ ecma_plugin_transform = [
196196
]
197197

198198
# Use `stacker` to avoid stack overflow.
199-
stacker = ["swc_ecma_parser/stacker", "swc_ecma_utils/stacker"]
199+
stacker = ["swc_ecma_parser/stacker", "swc_common/stacker"]
200200

201201

202202
typescript = ["swc_typescript"]

0 commit comments

Comments
 (0)