Commit Graph

496 Commits

Author SHA1 Message Date
kdy1
15e5d9ce79 Chores (#563)
- updated README.md (open collective)
 - fixed travis
2020-01-04 08:54:34 +00:00
강동윤
78daec2c14
Re-enable travis to make bors work (#562) 2020-01-04 15:58:21 +09:00
강동윤
c0cc2185ea
Fix ci (#561)
- line endings are normalized
 - switched to github actions from travis to check forked branches
2020-01-04 13:33:25 +09:00
David Sherret
c43bc471dd Fix span for patterns with a type annotation (#558)
swc_ecma_parser:
* fix span for patterns with a type annotation.

Co-authored-by: 강동윤 <kdy1997.dev@gmail.com>
2020-01-03 14:37:48 +09:00
David Sherret
5acf557e35 GetterProp - Add type_ann (#557)
swc_ecma_ast:
 - add type_ann to GetterProp

swc_ecmascript_parser:
 - parse type annotation after a getter property
2020-01-03 13:08:27 +09:00
강동윤
1bcfcb741a
Fix #555 (#556) 2020-01-03 12:19:39 +09:00
강동윤
806a6d97da
Regenerator (#554)
swc_ecma_transforms:
 - implement regenerator pass
 - add regenerator pass to es2015 preset

swc_ecma_preset_env:
 - add regenerator
2020-01-02 20:53:06 +09:00
David Sherret
5f6b11348a Fix span of the switch statement. (#553) 2020-01-02 16:46:56 +09:00
강동윤
05b7328002 lint 2020-01-02 13:29:19 +09:00
강동윤
94a81c9492 Make .take_all() efficient 2020-01-02 13:28:30 +09:00
David Sherret
bac1cb52a3 Add a take_all() method to Comments. (#552) 2020-01-02 13:21:43 +09:00
David Sherret
4f76cddebd Fix span of await token in for/for-in/for-of stmts. (#551) 2020-01-02 10:18:20 +09:00
David Sherret
288008091a Typo (#550) 2020-01-02 10:13:47 +09:00
강동윤
916858ae81
Bugfixes (#549)
swc_ecma_ast:
 - fix TsExprWithTypeArgs (closes #548)

swc_ecma_codegen:
 - allow using default import with namespace import (closes #546)

swc_ecma_parser:
 - parse import.meta (closes #545)
2020-01-01 06:57:34 +09:00
David Sherret
64bddebb2b Fix parsing class properties as readonly (#547)
swc_ecma_parser
 - parse readonly property correctly
2020-01-01 03:14:46 +09:00
David Sherret
708efebac9 Fix comment line's end to be on same line (#544)
- fix comment line's end to be on same line.
2019-12-30 11:09:45 +09:00
강동윤
aa2a394f7d
Fix #542 (#543)
swc_ecma_transforms:
 - preserve space after a jsx element
2019-12-30 00:05:43 +09:00
David Sherret
bde5341bd7 Fix string literal span on import/export specifiers to only include string literal (#540) 2019-12-29 16:18:14 +09:00
강동윤
31c1bc8a8a Use browserslist by default if env is specified but targets are not specified 2019-12-28 23:43:23 +09:00
강동윤
a8d7482294 Revert "Run browserslist if the target is not specified"
This reverts commit f0c2021c5e.
2019-12-28 23:08:02 +09:00
강동윤
f0c2021c5e Run browserslist if the target is not specified 2019-12-28 23:06:39 +09:00
강동윤
702800e0d9
Attach comments to correct node (#541) 2019-12-28 22:02:58 +09:00
강동윤
3cf1caa4b1 Bump version 2019-12-28 14:05:12 +09:00
강동윤
8562d3fbfb
Fix parser (#539)
swc_ecma_parser:
 - mark `declare` as `declare` (#538)
 - fix span of `export * from 'foo'` (#535)
2019-12-28 12:19:44 +09:00
강동윤
6fa85b646f
preset-env (#537)
swc_ecma_preset_env:
 - can inject polyfills automatically
 - can apply transforms automatically

swc:
 - added env config to .swcrc
2019-12-28 11:25:54 +09:00
강동윤
b98f17b84d Bump versions 2019-12-26 08:53:13 +09:00
David Sherret
32860576f2 Comment and TokenAndSpan - Implement Spanned (#534) 2019-12-26 08:35:43 +09:00
강동윤
31a5bed497
Legacy decorator for class and class members (#531) 2019-12-25 19:30:16 +09:00
강동윤
ac3f69acd0
Split tests to reduce compile time (#530) 2019-12-24 22:53:48 +09:00
강동윤
e2764e997b Transform for nullish coalescing operator.
Fixes #526.
2019-12-24 18:01:27 +09:00
강동윤
b1e4122b02
Nullish coalescing / optional chaining / comments (#529)
swc_ecma_ast:
 - rename `TsOptChain` to `OptChainExpr` (Fixes #525)
 - add `BinOp::NullishCoalescing`

swc_ecma_parser:
 - parse `??` (Fixes #526)

swc_ecma_transforms:
 - remap comments from fixer (Fixes #528)
2019-12-24 17:01:32 +09:00
강동윤
d8541c4f63 Fix a bug 2019-12-23 14:37:25 +09:00
David Sherret
668c2713d9 Support numeric separator for typescript. (#524) 2019-12-23 14:35:58 +09:00
강동윤
24b5c44ba3
Numeric separator & Bigint (#523)
swc_ecma_ast:
 - `BigInt` literal

swc_ecma_parser:
 - numeric separators. (#521)
 - parsing of bigint literal
2019-12-22 17:14:04 +09:00
강동윤
ed8ba26ae6 Fix tests 2019-12-21 17:09:53 +09:00
강동윤
6186af04a9
Fix handling of jsx texts (#519)
swc_ecma_transforms:
 - Fix handling of jsx texts (#517)
2019-12-21 16:59:04 +09:00
강동윤
51d21af031 Fix #516 2019-12-19 13:08:52 +09:00
강동윤
30af06bb70
Ast (#513)
swc_ecmascript:
 - add `ExprStmt`.
 - change type of regex.expression and regex.flags.
2019-12-16 18:08:21 +09:00
강동윤
f9a649ff7a Bump version 2019-12-15 08:15:26 +09:00
David Sherret
fb9539df6f Expose token module. (#510)
swc_ecma_parser:
- expose token module
2019-12-15 08:08:13 +09:00
강동윤
42ad8a92a2 ParseOptions.target 2019-12-14 18:57:44 +09:00
강동윤
332061f44d
Parser: respect jsc.target (#507)
swc:
 - make parser respect `jsc.target`.
2019-12-14 18:51:08 +09:00
kdy1
3ec395ba75 Improve performance & update rustfmt (#504) 2019-12-13 06:21:25 +00:00
강동윤
6fc91f2017 Remove #[inline(never)] 2019-12-13 08:47:46 +09:00
강동윤
5076249c90 fixup! Add a test for #503 2019-12-13 08:38:46 +09:00
강동윤
126b6bc761 Add a test for #503 2019-12-13 08:35:32 +09:00
kdy1
0df908fdb4 ast & parser improvement (#502)
Parser can now parse typescript source code and rxjs.

Closes #468.
2019-12-11 14:28:35 +00:00
강동윤
8622193d04 ParseOptions.is_module 2019-12-11 16:18:47 +09:00
강동윤
d53c94f1fb Bump parser's version.
Closes #500
2019-12-11 15:56:27 +09:00
kdy1
fa98c470d6 Program instead of Module (#499)
This pr adds an option to parse file as script, not module.


Related: https://github.com/swc-project/swc/issues/491
2019-12-11 06:07:21 +00:00