Commit Graph

26 Commits

Author SHA1 Message Date
강동윤
14f5212d3d
Wasm (#691) 2020-05-07 18:17:57 +09:00
강동윤
ffbb5163aa Bump version 2020-03-06 11:06:45 +09:00
강동윤
88d3062e5d Fix 2020-03-05 11:36:50 +09:00
Zimon Dai
ec086a1dab use 2018 edition syntax (#479) 2019-12-02 17:10:05 +09:00
강동윤
b46c4ec300
Update dependencies (#464) 2019-11-24 14:17:27 +09:00
Jasper De Sutter
716bfe05b2 Cleanup (#448)
- cargo fix
- update all crates to 2018 edition
2019-11-17 13:21:53 +09:00
강동윤
ae3326cd9d
Compiler apis & .swcrc improvement (#434)
- Expose high-level compiler apis (#431)
 - Support multiple entries in .swcrc (#414)
2019-10-25 10:11:24 +09:00
강동윤
10cb9a4b21
Publish (#278)
- swc_macros_common@0.2.0
 - ast_node@0.4.1
 - string_enum @0.2.0 
 - swc_ecma_ast@0.8.0
 - swc_ecma_parser_macros@0.3.0
 - swc_ecma_codegen_macros@0.3.0
 - swc_ecma_parser@0.9.1
 - swc_ecma_parser@0.6.1
2019-02-27 10:42:22 +09:00
강동윤
b516c19133
Update dependencies (#135) 2019-02-07 00:05:25 +09:00
강동윤
a26cc61a69 Build on stable rust 2019-01-19 09:25:47 +09:00
강동윤
4ff6d4ed4a
Performance & Node binding (#84)
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
강동윤
84675d32df
Visitor (#69)
* Add Visit<T> and VisitWith<F>

* implement derive(VisitWith<T>)

* Bump versions
2018-11-19 13:02:55 +09:00
강동윤
3786c5f788
Make procmacro2_semver_exempt optional for FromVariant (#68)
- use call_site if cfg(procmacro2_semver_exempt) is false

 - Make `FromVariant` not to emit extern crate swc_common
2018-11-18 21:18:11 +09:00
강동윤
cd51cb1731
Make procmacro2_semver_exempt optional (#67)
* Reduce compile time of tests.

* Make procmacro2_semver_exempt optional

* Bump versions
2018-11-18 19:57:35 +09:00
강동윤
1d0c78de6c
More works (#66)
ecma_transforms:
 - implement es2015::instanceof
 - implement es2015::typeof_symbol
 - implement inline_globals pass

ecma_parser:
 - `PResult<T>` is now `Result<T, ()>` and `Err(())` means that an error is emitted.
 - add docs
2018-11-18 14:00:07 +09:00
강동윤
9d7af34aab
Initial release (#45)
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
강동윤
f9be576e02
Ecmascript codegen (#40)
Comment is not fully supported yet
2018-10-25 13:17:05 +09:00
강동윤
0a5f3f4ab5
rustup to 2018-08-29\ (#39)
- libswc is broken
2018-09-16 20:25:41 +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
강동윤
e1764f907b [WIP] Make ast nodes contain span
* `struct Expr` + `enum ExprKind` -> `enum Expr`

`Expr` / `ExprKind` approach does not work well with recursive
 processing based on the type system because we can't access common
 fields like span while processing child node like `MemberExpr`.

As ast processing is inherently recursive, we should use a
 recursive-friendly approach.

 * `#[derive(FromVariants)]`
It creates lots of `From<T>` to help using ast enums as a real sum type.

 * `#[derive(Spanned)]`

Inspired by https://docs.rs/syn/0.12.13/syn/spanned/trait.Spanned.html

It does not handle attributes yet.

 * Parser is not updated yet.
2018-03-03 19:37:01 +09:00
강동윤
171abda3c0 Implement #[derive(StringEnum)] 2018-03-02 14:50:50 +09:00
강동윤
c37454ca1f Use Span::def_site() instead of Span::call_site()
* Now rustdoc contains derived implementations.
2018-03-01 14:09:22 +09:00
강동윤
4a30fb3436
Testing framework (#31)
- 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
강동윤
11b12b8142 Update rustfmt to 0.3.5 and format literals. 2018-01-16 20:11:08 +09:00
강동윤
e949c40517
ECMAScript parser (#1)
- Parser and lexer for lastest ecma spec https://tc39.github.io/ecma262

  - Lexer is currently very inefficient

 - Use https://github.com/tc39/test262-parser-tests/ for testing.

 - Implement proc-macro based ast folder and assert_eq_ignore_span! based on it.

 - Some utilities for proc macro at /macros/common
2018-01-12 16:53:06 +09:00
강동윤
0f9532dd5d initial commit 2017-12-22 22:07:03 +09:00