Donny/강동윤
581aafb4df
perf(visit): Introduce Pass
API and adjust visitor APIs for it ( #9680 )
...
**Description:**
- `Pass`: `FnMut(&mut Program)`.
**Breaking Changes:**
- `chain!`: Use a tuple instead. You can replace all `chain!(` with `(` with IDE feature and it will work.
- `chain!` with 13 or more args: Use nested tuples for items after 13th element.
**Related issue:**
- Related to https://github.com/swc-project/swc/issues/9601
2024-10-29 11:25:16 +09:00
Donny/강동윤
af922d83e5
feat(es/minifier): Support mangle cache ( #9489 )
...
**Description:**
This PR adds a name cache for the mangler. It's implemented using a `Mutex`, and it's exposed to JS as an experimental API. Note that JS API only provides an opaque object.
2024-08-25 23:42:53 +00:00
Donny/강동윤
279ea910e0
build: Update rustc
to nightly-2024-07-21
( #9319 )
2024-07-23 05:31:35 +00:00
Donny/강동윤
76fe139334
perf(es/minifier): Pre-allocate collections ( #9289 )
...
CI / Cargo fmt (push) Waiting to run
CI / Cargo clippy (push) Waiting to run
CI / Check license of dependencies (push) Waiting to run
CI / Check (macos-latest) (push) Waiting to run
CI / Check (ubuntu-latest) (push) Waiting to run
CI / Check (windows-latest) (push) Waiting to run
CI / Test wasm (binding_core_wasm) (push) Waiting to run
CI / Test wasm (binding_minifier_wasm) (push) Waiting to run
CI / Test wasm (binding_typescript_wasm) (push) Waiting to run
CI / List crates (push) Waiting to run
CI / Test - ${{ matrix.settings.crate }} - ${{ matrix.settings.os }} (push) Blocked by required conditions
CI / Test node bindings - ${{ matrix.os }} (macos-latest) (push) Waiting to run
CI / Test node bindings - ${{ matrix.os }} (windows-latest) (push) Waiting to run
CI / Test with @swc/cli (push) Waiting to run
CI / Miri (better_scoped_tls) (push) Waiting to run
CI / Miri (string_enum) (push) Waiting to run
CI / Miri (swc) (push) Waiting to run
CI / Miri (swc_bundler) (push) Waiting to run
CI / Miri (swc_ecma_codegen) (push) Waiting to run
CI / Miri (swc_ecma_minifier) (push) Waiting to run
CI / Done (push) Blocked by required conditions
Benchmark / Bench everything (push) Waiting to run
**Related issue:**
- Inspiration: https://github.com/oxc-project/oxc/pull/4328
2024-07-20 10:26:10 +09:00
Donny/강동윤
a417ff4d86
feat(allocator): Add maybe
types ( #9278 )
2024-07-19 13:22:34 +09:00
Donny/강동윤
b2491e5461
refactor(common): Drop SyntaxContext
from AST nodes ( #9175 )
2024-07-12 13:13:20 +09:00
Donny/강동윤
e7b9c552a7
chore(ci): Configure codspeed
( #9189 )
2024-07-10 15:20:27 +09:00
David E Disch
df2e056f29
refactor(es/minifier): Remove mangle.safari10
( #8857 )
...
**Related issue:**
- Closes #8837
2024-04-16 03:05:43 +00:00
Donny/강동윤
9a0572b968
refactor(swc_node_base): Rename to swc_malloc
( #8272 )
...
**Description:**
This is quite convinient.
2023-11-11 19:10:56 +00:00
Donny/강동윤
ee7575695d
feat(es/codegen): Add an option to print assert
for import attributes ( #7914 )
...
**Description:**
- `jsc.experimental.keepImportAssertions` is renamed to `jsc.experimental.keepImportAttributes`.
- `jsc.experimental.emitAssertForImportAttributes` is added.
**Related issue:**
- Closes #7908
2023-09-05 21:24:25 +09:00
Donny/강동윤
eff0caca2b
feat(es/minifier): Support mangle.eval
( #7777 )
...
**Related issue:**
- Closes #7754
2023-08-09 20:42:12 +00:00
Donny/강동윤
0259a7465f
build(cargo): Update rustc
to nightly-2023-03-20
( #7170 )
...
**Description:**
This PR also updates `rkyv` to `=0.7.40`.
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6807 .
2023-03-30 08:06:02 +00:00
Donny/강동윤
12546c853a
build(cargo): Revert rustc upgrade ( #7162 )
...
**Description:**
The `rkyv` bug is not fixed.
2023-03-29 17:48:45 +09:00
Donny/강동윤
e445502072
build(cargo): Update rustc
to nightly-2023-03-28
( #7154 )
...
**Description:**
This PR also updates `rkyv` to `=0.7.40`.
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6807 .
2023-03-29 06:24:19 +00:00
Donny/강동윤
963c460613
refactor: Fix lints using clippy from nightly-2023-03-13
( #6920 )
2023-03-14 04:56:21 +00:00
Donny/강동윤
ec7e913815
fix(es/minifier): Make name mangler respect toplevel
( #6774 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6418 .
2023-01-10 06:42:49 +00:00
Donny/강동윤
1085667049
perf(es/minifier): Enable parallel processing ( #5705 )
2022-09-01 13:36:30 +09:00
Donny/강동윤
99a474cb2d
refactor(es/minifier): Use Program
instead of Module
( #4969 )
2022-06-14 16:33:38 +00:00
Donny/강동윤
eb8508f88c
feat(es/codegen): Implement ascii-only ( #4660 )
2022-05-15 05:07:21 +00:00
Donny/강동윤
53610fdafc
feat(es/resolver): Use different syntax context for unresolved refs ( #4436 )
...
- We don't need a list of bindings to check if an identifier is unresolved.
- Checking if an identifier is unresolved is now one CPU instruction.
- Previously it was one hashmap operation.
- This PR also improves performance, by removing the hashmaps mentioned above.
2022-04-26 07:38:50 +00:00
Donny/강동윤
a8eb00cc54
perf(es/minifier): Change default value of passes
to 3
( #4373 )
2022-04-19 22:02:33 +00:00
Donny/강동윤
5d179bfd7d
chore(es/minifier): Setup correct benchmark ( #4372 )
2022-04-19 18:12:04 +00:00
Donny/강동윤
8309440008
chore(es): Rename benchmarks ( #4355 )
2022-04-17 18:36:15 +00:00
Donny/강동윤
66ff7b8a09
perf(es/minifier): Make name mangler faster ( #4342 )
2022-04-17 15:35:36 +09:00
Donny/강동윤
97dfcb9ccb
chore(es/minifier): Add logging ( #4156 )
2022-03-25 06:44:07 +00:00
Donny/강동윤
107c91dd20
perf(es/minifier): Make mangler faster by merging hash sets into one ( #3983 )
2022-03-12 06:16:02 +00:00