Ronan Amsterdam
a228daec58
magic comment regexp match update and statsCase test updated
...
plus minor renamings and snapshot update
2018-05-30 13:18:43 +08:00
Florent Cailhol
25ec7e4102
Do not stop processing on error
2018-05-29 13:17:36 +02:00
Florent Cailhol
4b1a76bdb0
Deprecate Parser.getCommentOptions
...
Use Parser.parseCommentOptions(range) instead.
2018-05-29 11:09:34 +02:00
Ronan Amsterdam
d91e7ecafc
getCommentOptions renamed to getCommentOptionsStrict
...
and wrapped back in getCommentOptions to avoid possible breaking changes
2018-05-29 16:25:10 +08:00
Ronan Amsterdam
1969485f05
warning class and propagation added to ImportParserPlugin
...
and invalid-import tests moved to the statsCases
2018-05-29 15:29:23 +08:00
Ronan Amsterdam
48a8d8534a
webpackCommentRegExp moved outside of getCommentOptions()
...
per review request
2018-05-28 15:55:16 +08:00
Ronan Amsterdam
49bd54313d
Issue #7395 : webpack import options comments warning propagation
2018-05-27 11:32:00 +08:00
Tobias Koppers
eda273d579
Merge pull request #7236 from webpack/lint/more-strict-jsdoc
...
More strict linting of jsdocs
2018-05-09 09:59:18 +02:00
Florent Cailhol
da6f869c1e
Fix edge case when parsing top-level this on IIFE
2018-05-08 19:31:01 +02:00
Tobias Koppers
f2ad440de8
More strict linting of jsdocs
...
Use TODO over any when type is possible
2018-05-08 14:53:33 +02:00
Florent Cailhol
54c0cd76b6
Always return object with the same shape
2018-04-10 21:18:12 +02:00
Florent Cailhol
a8b32acad5
Fix top level detection in the Parser
2018-04-06 09:40:37 +02:00
Tobias Koppers
1b50e4e96d
Merge pull request #6833 from webpack/ellipsis
...
Use ellipsis instead of '...'
2018-03-29 11:00:28 +02:00
Jan Potoms
daca9cbc18
expand
2018-03-28 12:08:14 +02:00
Jan Potoms
6f8b281bf4
make prettier
2018-03-28 11:02:17 +02:00
Jan Potoms
3c699eb1f8
oops
2018-03-28 10:54:55 +02:00
Jan Potoms
5146ee55e6
Don't detect exportDeclaration when named function expression
...
Fixes #6867
2018-03-28 10:54:41 +02:00
Florent Cailhol
3983803d30
Destructure 'require' to improve readability
2018-03-22 12:05:58 +01:00
Florent Cailhol
72786beee7
Use ellipsis instead of '...'
2018-03-22 10:54:18 +01:00
Naveen Jain
1ab9fdb8b0
Fixed Parser so that this Expression can work with ProvidePlugin
2018-02-27 06:02:09 +05:30
Tobias Koppers
f32bd41c52
fix linting
2018-02-25 02:15:37 +01:00
Tobias Koppers
5238159d21
run prettier on existing code
2018-02-25 02:00:20 +01:00
Florent Cailhol
490a32cfea
Update parser to support EcmaScript 2018
2018-02-07 10:39:06 +01:00
Florent Cailhol
b8815a9415
Leave top level scope when traversing Class nodes
2018-01-25 09:57:47 +01:00
Florent Cailhol
86e6edf1ab
Refactor how source type is handled by the parser
2018-01-22 09:30:43 +01:00
Florent Cailhol
5a1ffb53dc
Use acorn@5
2018-01-18 11:34:30 +01:00
Tobias Koppers
47f26013d7
Merge pull request #6261 from ooflorent/top_level_this
...
Rewrite top level `this` to `undefined` in Harmony modules
2018-01-14 00:28:16 +01:00
Florent Cailhol
a550a8cf62
Rewrite top level this to undefined in Harmony modules
2018-01-13 15:25:41 +01:00
Tobias Koppers
416247102a
Merge pull request #6288 from ooflorent/fix_variable_hook
...
Fix VariableDeclaration visitors
2018-01-12 10:58:03 +01:00
Tobias Koppers
e6fb58d1fc
Merge pull request #6273 from ooflorent/fix-4857/unreachable_branches
...
Eliminate unreachable branches
2018-01-12 10:55:27 +01:00
Florent Cailhol
c9ff97fa7e
Eliminate unreachable branches
...
Webpack does not transpile unreachable branches leaving `import` expressions
in the code. This PR modifies `ConstPlugin` to remove the unreachable branch.
Before:
```js
if (true) { 1 } else { import("a") }
if (false) { import("a") } else { 1 }
true ? 1 : import("a");
false ? import("a") : 1;
```
After:
```js
if (true) { 1 } else {}
if (false) {} else { 1 }
true ? 1 : null;
false ? null : 1;
```
2018-01-11 19:35:24 +01:00
Florent Cailhol
e44ba306a0
Fix VariableDeclaration visitors
2018-01-11 15:56:41 +01:00
Florent Cailhol
bc05ee3f75
Fix parser hooks
2018-01-10 20:52:33 +01:00
Florent Cailhol
10490c947d
Remove unused methods
2018-01-04 13:55:26 +01:00
Florent Cailhol
5e616ec8de
Make enter calls static
2018-01-03 22:53:37 +01:00
Florent Cailhol
71f5abf7ae
Remove forEach closures to reduce GC
2018-01-03 22:44:17 +01:00
Tobias Koppers
8a38c4bd34
add support for empty catch clause
...
fixes #6220
2018-01-01 10:49:19 +01:00
Tobias Koppers
8a79c213e7
fix support for patterns in for in/of statements
...
add test case
2018-01-01 10:48:56 +01:00
Florent Cailhol
48b412453c
Make walk/prewalk calls static
2017-12-31 18:09:26 +01:00
Florent Cailhol
9669c9e013
Use Parser#hooks instead of Tapable#plugin
2017-12-21 09:08:10 +01:00
Cody Ogden
f5b57f4764
Extract TrackingSet class from the Parser.js module.
...
@TheLarkInn suggested this class be extracted from this file during the live stream tonight. A similar class was removed and placed in the directory.
- Created
2017-12-20 01:37:49 -06:00
Tobias Koppers
758f1eb464
Merge branch 'master' into next
2017-12-12 14:45:09 +01:00
Florent Cailhol
da08376fd9
Evaluate bitwise and exponential operations
2017-12-05 17:16:45 +01:00
Tobias Koppers
85951d33be
Merge branch 'master' into next
2017-12-05 09:03:45 +01:00
Nikhil Gaba
5ab6972634
Improve Parser to recognize 'new Foo(...)' type expressions
2017-12-01 16:43:39 -08:00
Tobias Koppers
dffedccc75
reduce memory usage
2017-11-29 12:08:52 +01:00
Tobias Koppers
c10da6c285
upgrade tapable from Parser
2017-11-28 10:25:48 +01:00
Tobias Koppers
5a4f0aca67
change imports of tapable to old version
...
prepare to migrate to new tapable version
2017-11-27 20:56:42 +01:00
Tobias Koppers
75f68a2635
fixes linting, remove not needed context arguments
2017-11-08 20:49:41 +01:00
Tobias Koppers
f7c2f8e470
Update code style to arrow functions
2017-11-08 11:56:01 +01:00