15033 Commits

Author SHA1 Message Date
Hirotaka Tagawa / wafuwafu13
6c684f9b54
Convert @babel/plugin-transform-spread to TypeScript (#13770)
Co-authored-by: Nicolò Ribaudo <nicolo.ribaudo@gmail.com>
2021-10-01 01:37:04 +02:00
Huáng Jùnliàng
89cab4311c
fix: remove imported types from export (#13800)
* fix: remove imported types from export

* add onlyRemoveTypeImports testcase
2021-09-28 15:13:37 -04:00
NotWearingPants
767b72f9c2
[skip-ci] Fixed typo in issues' welcome comment in CI (#13797) 2021-09-27 11:49:03 +02:00
NotWearingPants
26d0a7e10f
Fix Gulpfile path separator issue on Windows (#13795) 2021-09-26 23:51:05 +02:00
Huáng Jùnliàng
14572e1881
Sort module export names (#13788)
* fix: sort export init statements by name

* update test fixtures

* refactor: reduce memory footprint

* review comments
2021-09-26 10:12:18 -04:00
Julien Wajsberg
6818b22dc0
[@babel/node] Forward the signal SIGTERM as well (#13784) 2021-09-25 10:18:10 +02:00
Babel Bot
8960f9e68e
Update test262 (#13789) 2021-09-24 17:59:13 +02:00
Huáng Jùnliàng
178d43ff17
Tokenize keywords-like identifier as new tokens (#13769)
* refactor: add more identifier token helpers

* refactor: explode tt.name into multiple tokens

* fix: disallow escape in interface keyword

* refactor: simplify isMaybeDefaultImport

* review comments

* refactor: avoid string comparison
2021-09-23 10:54:44 -04:00
Nicolò Ribaudo
613ae6fac7
Update polyfill plugins (#13781)
* Update polyfill plugins

* Babel 8
2021-09-23 09:24:45 +02:00
Nicolò Ribaudo
2e2d202694
[babel 8] Materialize ESTree's classFeatures option (#13752)
* [babel 8] Enable ESTree classFeatures by default in @babel/parser

* Fix `visitorKeys`

* Update tests
2021-09-22 15:28:10 -04:00
Babel Bot
3d1481f363 Add v7.15.7 to CHANGELOG.md [skip ci] 2021-09-17 23:06:44 +00:00
Babel Bot
8d0294edf8 v7.15.7 2021-09-17 22:54:10 +00:00
Nicolò Ribaudo
a815d7dd10
Update Jest to 27.2.0 (#13776)
* Update Jest to `27.2.0`

* Update
2021-09-17 19:02:36 +02:00
Nicolò Ribaudo
422b87a76f
Update to @nicolo-ribaudo/chokidar-2@2.1.8-no-fsevents.3 (#13775) 2021-09-17 11:29:12 -04:00
Huáng Jùnliàng
d2076a531f
Store token type as number (#13768)
* refactor: abstract token metadata access

* refactor: move token-specific update context logic

* refactor: centralize token definitions

* refactor: abstract token type creation

* refactor: use number as token storage

* build: replace tt.* as number

* fix flow errors

* fix: build on Node 12

* Update packages/babel-parser/src/tokenizer/types.js

Co-authored-by: Nicolò Ribaudo <nicolo.ribaudo@gmail.com>

* refactor: rename token types exports to tt

* update unit test

* test: update Babel 8 test fixtures

* fix: centralize obsolete token type updateContext

* fix flow errors

Co-authored-by: Nicolò Ribaudo <nicolo.ribaudo@gmail.com>
2021-09-17 09:36:11 -04:00
Babel Bot
eec8372b56
chore: update test262 to 650e7add4a4a2d9ee468d2e7625c0b68c130be04 (#13774) 2021-09-17 09:00:53 +02:00
JuniorTour
da79c90f2a
fix(babel-parser): Allow line break before assert return type (#13771) 2021-09-16 23:24:11 +02:00
Nicolò Ribaudo
8fb50429ea
Throw a better error when transforming imported bindings in types (#13739)
* Throw a better error when transforming imported bindings in types

* Also type casts

* Update error message
2021-09-16 23:14:41 +02:00
Nicolò Ribaudo
2ffb19828f
Update to Yarn 3 (#13140) 2021-09-16 22:23:46 +02:00
Steven Degutis
137fecc765
Move pipeline operator to Stage 2 (#13754) 2021-09-16 17:54:31 +02:00
Nicolò Ribaudo
69ae2388f8
Fix regexpu-core bundling in @babel/standalone (#13767) 2021-09-15 23:45:30 +02:00
Huáng Jùnliàng
a27c1b8881
Update Identifier definitions to Unicode 14 (#13759) 2021-09-15 07:33:13 -04:00
Nicolò Ribaudo
f57bb79791
Update regexpu-core (#13764) 2021-09-15 07:30:21 -04:00
Nicolò Ribaudo
710b3919fa
[estree] Fix conversion of PrivateName in MemberExpression (#13755)
* Update test

* [estree] Fix conversion of `PrivateName` in `MemberExpression`
2021-09-14 17:14:04 +02:00
Nicolò Ribaudo
8af57dbfb7
[eslint-parser] Represent static using a Keyword token (#13751) 2021-09-13 16:35:32 +02:00
TagawaHirotaka
9780c5667f
Replace the deprecated produceCachedData option used in vm module with script.createCachedData() (#13741)
* Replace the deprecated vm produceCachedData option with createCachedData

* Use BABEL_8_BREAKING flag
2021-09-12 01:09:05 +02:00
Kristoffer K
0ca601a86f
chore: add constraint for duplicate dependency declarations (#13744) 2021-09-10 09:08:01 +02:00
Babel Bot
37e1b91b74
chore: update test262 to 66a3c3aa8b6170f84613dc66a87cd50c68e505df (#13745) 2021-09-09 20:13:53 -04:00
Babel Bot
be33f6a907 Add v7.15.6 to CHANGELOG.md [skip ci] 2021-09-09 19:35:48 +00:00
Babel Bot
34a27e46f8 v7.15.6 2021-09-09 19:22:51 +00:00
Nicolò Ribaudo
3c3f5205c9
Fix right precedence of Hack pipes (#13668) 2021-09-08 17:38:07 +02:00
TagawaHirotaka
8c061f0848
Use @types/node for vm module (#13738) 2021-09-08 15:56:25 +02:00
Daniel Kezerashvili
40e43f5a14
fix: Duplicate function call in variable destructuring (#13711)
* Add test case demonstrating invalid behavior

* Add conditional check for child properties so RHS is not duplicated

* Add recursive check to find any nested non single-property case

* Add case for array destructuring

* Add test case for a nested rest element

* More safely recurse through array destructuring

* Traverse assignment and nested rest operations

* Refactor to be more clear which case statement we are executing against

* Update missed snapshots

* Update packages/babel-plugin-proposal-object-rest-spread/src/index.js

Co-authored-by: Huáng Jùnliàng <jlhwung@gmail.com>

* Filter null array elements, add early return, remove optional chaining

* Use stronger type assertions

* Update fall through to be false; add early return to RestElement case

* Move hasMoreThanOneBinding to its own file with distinct tests

* Rename testing helper to more appropriately match business logic

* Yarn Dedup & rename hasMoreThanOneBinding to shouldStoreRHSInTemporaryVariable

Co-authored-by: Huáng Jùnliàng <jlhwung@gmail.com>
2021-09-07 17:27:52 -04:00
Huáng Jùnliàng
d87a3d9e13
id in import attributes should not be referenced (#13733) 2021-09-07 08:29:15 -04:00
Yvan Zhu
1ebc5b7f7b
Remove duplicate dependency and devDependency in preset-env (#13737)
Co-authored-by: zhuyunfeng <ext.zhuyunfeng1@jd.com>
2021-09-07 14:27:03 +02:00
Sosuke Suzuki
c25ec3e069
[babel-parser] add tests for static blocks with line breaks (#13734) 2021-09-04 16:27:38 +02:00
Sosuke Suzuki
62e42a3f60
fix(babel-parser): Fix end of range of SequenceExpression (#13731) 2021-09-04 12:01:20 +02:00
Babel Bot
0d5ca876fd Add v7.15.5 to CHANGELOG.md [skip ci] 2021-09-04 08:59:16 +00:00
Babel Bot
e82e43ca33 v7.15.5 2021-09-04 08:50:23 +00:00
Nicolò Ribaudo
44388e6e81
Disallow #a in #b in c and similar expressions (#13727)
* Disallow `#a in #b in c` and similar expressions

* Update packages/babel-parser/src/parser/expression.js

Co-authored-by: Huáng Jùnliàng <jlhwung@gmail.com>

* Add test for `await #x in`

* Flow

* Update flow allowlist

* Flow

Co-authored-by: Huáng Jùnliàng <jlhwung@gmail.com>
2021-09-04 10:05:09 +02:00
Babel Bot
5a361fedb4
Update test262 (#13729) 2021-09-04 09:40:42 +02:00
Federico Ciardi
66cadea103
Revert "fix: non breaking align options naming" (#13732)
This reverts commit 51a0caa8a2dac2651856035760413d76fb422d77.
2021-09-04 09:34:41 +02:00
Babel Bot
5fcf876c57 Add v7.15.4 to CHANGELOG.md [skip ci] 2021-09-02 23:45:22 +02:00
Babel Bot
b2376757d7 v7.15.4 2021-09-02 21:28:31 +00:00
Huáng Jùnliàng
51c6a99c8e
getBindingIdentifiers should return params for private methods (#13723)
* docs: add comments on binding kind

* refactor: simplify For collector visitor

* getBinding does not return falsy values

* chore: table style tests

* add more test cases

* fix: return params for private methods
2021-09-02 21:55:39 +02:00
Nicolò Ribaudo
b335dcc67f
Don't manually update npm in CRA test on CircleCI (#13725) 2021-09-02 19:24:30 +02:00
Nicolò Ribaudo
fce0cffc30
Use npm@7 for CRA e2e test (#13724) 2021-09-02 08:16:20 -05:00
Huáng Jùnliàng
1f79784a99
archive stage 4 parser plugins (#13717)
* archive stage 4 parser plugins

* use npm protocol for archived plugins

* fix: get module.exports from archived plugins

* remove syntax-top-level-await from test options

* use npm syntax-class-static-block
2021-09-01 15:35:24 -04:00
Nicolò Ribaudo
804a94f829
Use import.meta.url instead of __dirname (#13721) 2021-09-01 15:57:55 +02:00
Nicolò Ribaudo
4ffbcc4bb2
Don't load top-level config in internal test (#13720) 2021-09-01 15:57:41 +02:00