Commit Graph

22 Commits

Author SHA1 Message Date
Donny/강동윤
a86e9f3bb5
fix(es/module): Fix jsc.paths for projects using pnpm ()
**Related issue:**

- x-ref: https://vercel.slack.com/archives/C04DUD7EB1B/p1693911653100299?thread_ts=1693819683.070959&cid=C04DUD7EB1B
2023-09-06 17:29:47 +00:00
Donny/강동윤
99d48e305e
fix(plugin): Make span_to_source use dedicated function ()
**Related issue:**

 - Closes https://github.com/swc-project/swc/issues/6852.
 - Closes https://github.com/swc-project/swc/issues/6404.
2023-01-26 02:09:36 +00:00
Donny/강동윤
ec0d6d5a0d
feat(es/minifier): Improve trivial rules () 2022-10-13 23:34:30 +00:00
Donny/강동윤
3c3529cb84
build(rustc): Update rustc ()
**Description:**

This PR updates rustc, and fix some performance bugs of `swc_common`.
2022-09-24 03:33:47 +00:00
Donny/강동윤
a6d404a8c2
chore(repo): Configure prettier () 2022-05-04 14:25:28 +00:00
Donny/강동윤
978de5943e
chore(ci): Configure clippy () 2022-01-13 23:06:11 +09:00
Donny/강동윤
02322aaa99
chore: Make rust-analyzer faster () 2021-12-03 23:14:33 +09:00
Donny/강동윤
123c1f5d02
chore: Fix typo () 2021-10-19 08:25:57 +00:00
Donny/강동윤
63ad4b4322
fix(es/minifier): Fix minification of react hooks ()
swc_ecma_minifier:
 - `analyze`: Track for conditional usages.
 - `collapse_vars`: Don't inline a variable if usage it conditinal.
2021-10-17 15:24:17 +09:00
Donny/강동윤
6d35e7c28d
fix(swc): Fix order of custom passes ()
swc:
 - Invoke `resolver` and `typescript::strip` before applying user passes.
2021-10-05 20:46:49 +00:00
강동윤
8e237288d7
Migrate to napi () 2020-08-30 15:29:42 +09:00
강동윤
8615d69ac3
Fix bugs ()
swc_ecma_transforms:
 - Module passes resolver pass now shares 'global' context (Closes )
 - TypeScript enums are treated as concrete (Closes )
2020-04-30 23:48:52 +09:00
강동윤
d074063867
Parser: Error recovery ()
Implement some error recovery logic to parser
2019-11-17 18:36:47 +09:00
강동윤
4ff6d4ed4a
Performance & Node binding ()
swc_common:
 - update rustc-ap crates to v313

swc_ecma_ast:
 - use bool instead of Option<Span>


swc_ecma_parser:
 - remove LexerInput
 - use uncons_while
 - assert only on debug mode
 - use Visit instead of Fold while verifying
 - replace debug! with trace!
 - disable logging while benchmarking
 - drop slog

swc_ecma_transforms:
 - classes: fold Decl instead of Stmt

swc:
 - add nodejs binding
2018-12-21 16:54:36 +09:00
강동윤
9d7af34aab
Initial release ()
common:
 - rename `Folder` to `Fold`
 - folder.then()
 - impl Fold for Box<F>
 - impl Fold<T> for &mut F where F: Fold<T>

transforms:
 - make Simplifier private
 - organize compat

codegen:
 - use `Mark` to avoid deoptimization

swc:
 - upgrade rayon and use global thread pool instead
2018-11-10 17:44:35 +09:00
강동윤
eb2a2a7f15
Fix tests and lints ()
- Temporarilly ignored comment codegen tests.
 - Split Simplify into SimplifyExpr and SimplifyStmt
 - fix lints
2018-11-05 13:12:52 +09:00
강동윤
0e1ee5c560 Remove an obsolete setting. 2018-06-24 19:21:04 +09:00
강동윤
5d5f861b9d Update dependencies
- rustc toolchain to "nightly-2018-05-30"
 - rustfmt to 0.8.6
 - rustc-ap-* to 150
 - syn to 0.14
 - proc-macro2 to 0.4
 - quote to 0.6
2018-06-02 18:01:00 +09:00
강동윤
79f3660f0f
Downgrade rust toolchain to 2018-02-01 () 2018-03-09 16:56:43 +09:00
강동윤
ffe6fb9030 Add formatOnSave to settings.json 2018-03-04 14:09:36 +09:00
강동윤
10f83f3f02
Fix rls (again) ()
* Don't use `#[parser]` in lexer

* Don't use `#[parser]` in parser/util.rs

* Pin rust toolchain to nightly-2018-02-28
2018-02-28 14:35:52 +09:00
강동윤
4a30fb3436
Testing framework ()
- Make rls happy.
  - Some minor parser error improvements.
  - Add reference files for ecmascript parser errors.
  - Improve error message of import/export used outside of a module
2018-02-27 13:21:57 +09:00