Logan Smyth
51ddeade8a
Avoid renaming this bindings in simple arrow function cases.
2016-03-07 20:45:20 -08:00
Logan Smyth
db3a43869c
Remap across arrow function boundaries - fixes T7108
2016-03-07 20:45:19 -08:00
Logan Smyth
2e210927d8
Move the necessary exec transforms to the exec test.
2016-03-07 20:45:19 -08:00
Logan Smyth
836f398619
Re-use central inShadow logic.
2016-03-07 20:45:19 -08:00
Logan Smyth
8b8e3ddbec
Flatten inShadow logic for readability.
2016-03-07 20:45:18 -08:00
Amjad Masad
60d773f370
Merge pull request #3393 from babel/cache
...
Move NodePath cache out of the AST
2016-03-07 13:57:47 -08:00
Amjad Masad
5d0645e308
Merge pull request #3381 from keijokapp/fix-named-functionexpression-scoping-issue
...
Fix named async FunctionExpression scoping issue.
2016-03-07 13:39:52 -08:00
Amjad Masad
ec18fa0059
Add clearCache test
2016-03-07 12:50:57 -08:00
Amjad Masad
d5e78384ef
Only export methods and not the entire cache
2016-03-07 12:50:29 -08:00
Amjad Masad
fc19ac2af5
Remove merge artificats
2016-03-07 12:05:46 -08:00
Amjad Masad
403d6153fd
correct cache path
2016-03-07 12:04:44 -08:00
Amjad Masad
b53755422c
Move things around
2016-03-07 12:04:44 -08:00
Amjad Masad
bf91a68375
Move scope cache to the cache module
2016-03-07 12:04:44 -08:00
Amjad Masad
3c148148bc
Semicolon
2016-03-07 12:04:44 -08:00
Amjad Masad
5367d5d151
Make sure we update the cache in all the right places
2016-03-07 12:04:44 -08:00
Amjad Masad
29ef158204
Semis
2016-03-07 12:03:48 -08:00
Amjad Masad
b9a893aab6
Move NodePath cache out of the AST
...
As mentioned on the task https://phabricator.babeljs.io/T7179 having
this cache on the AST leads to all sorts of portability and reuse
bugs.
This moves the cache into a clearable WeakMap which will fix the
following:
1. Moving the AST between different babel versions or tools will not
lead into sharing potentially outdated cached information
2. `.clear()` can be called on the cache by a plugin to clear
potentially outdated information. This is helpful when implementing two
seperate pipelines that should not share information.
I think the next step (which is harder, I tried) is to isolate cache and
make it live on a transform or pipeline level state (like the `hub`).
The reason it is hard is because the `babel-traverse` main API -- although
requires the state object to be passed -- not many callers do. To fix
this we should release a patch version that warns about this and fix all
the internal callers. Next couple of releases we can start throwing when
no state is passed (or we can create our own state).
2016-03-07 12:03:48 -08:00
Amjad Masad
b7465843dd
Merge pull request #3375 from jmm/parameters-rest-optimization-errors
...
Fix errors in parameters rest transformation [T7138]
2016-03-07 11:58:15 -08:00
Amjad Masad
4b2a660ee0
Merge pull request #3323 from divmain/master
...
Source-map support for multiple input source files
2016-03-07 11:57:59 -08:00
Dale Bustad
3c6c09d00a
Only detect indent if babel-generator is provided code string, vs multi-source object.
2016-03-07 02:47:28 -08:00
Dale Bustad
288b3ba559
Attach filename property to node.loc when provided.
2016-03-07 02:47:28 -08:00
Dale Bustad
f007b51554
Accept filename-to-file-content hash as code parameter of generate.
2016-03-07 02:47:28 -08:00
Dale Bustad
26dcd6400f
When generating sourcemaps, use per-node source filename if present.
2016-03-07 02:47:27 -08:00
Henry Zhu
d7342542b7
Merge pull request #3385 from samwgoldman/def-site-variance
...
Add support for Flow def-site variance syntax
2016-03-06 18:00:38 -05:00
Sam Goldman
a38a58bad8
Add support for Flow def-site variance syntax
...
This syntax allows you to specify whether a type variable can appear in
a covariant or contravariant position, and is super useful for, say,
Promise.
Right now this is hacked in jankily, but in the next major release we
should stop using Identifier nodes for type parameters.
2016-03-06 14:44:09 -08:00
Henry Zhu
5eb13059e2
Merge pull request #3383 from babel/T7160
...
Regression with exporting an arrow function with a default param
2016-03-06 15:40:27 -05:00
Henry Zhu
57ef6a2b6a
v6.6.5
2016-03-04 18:16:17 -05:00
Henry Zhu
d915508877
remove misc alias files
2016-03-04 17:58:49 -05:00
Henry Zhu
5cc2037b1b
Merge pull request #3401 from babel/changelog-6.6.5
...
6.6.5 changelog [ci skip]
2016-03-04 17:55:55 -05:00
Henry Zhu
54cbefaa27
6.6.5 changelog [ci skip]
2016-03-04 17:47:26 -05:00
Henry Zhu
3689cae8e5
Merge pull request #3399 from babel/flow-comments
...
use flow instead of flow-comments
2016-03-04 16:24:28 -05:00
Henry Zhu
937b8a6767
use flow instead of flow-comments
2016-03-04 15:50:05 -05:00
Amjad Masad
92ed05640c
Merge pull request #3398 from babel/revert-rm-flow
...
Revert "Remove flow"
2016-03-03 16:07:24 -08:00
Amjad Masad
2d05996810
Merge pull request #3397 from babel/hzoo-patch-1
...
Make sure lib is clean before publishing
2016-03-03 15:22:54 -08:00
Amjad Masad
2f5a17fd90
fix eslint
2016-03-03 15:22:16 -08:00
Amjad Masad
2fbe28cc88
Remove remaining @flow annotations
2016-03-03 15:10:59 -08:00
Amjad Masad
12ee11a0a4
Revert "Remove Flow annotations and pragmas"
...
This reverts commit 4252244d06b225ab26a02d52c04f9940a3e4d6a2.
2016-03-03 15:03:55 -08:00
Henry Zhu
b8b6bc0602
Make sure lib is clean before publishing
2016-03-03 17:50:51 -05:00
Amjad Masad
3667527d04
Revert "Remove flow"
...
This reverts commit 2827ff6b01dcce69e9d3c0402e96b52b3a2a47ee.
2016-03-03 14:49:20 -08:00
Amjad Masad
b88182cacf
Merge pull request #3396 from AgentME/afterCompute
...
Fix T7183: Object accessors after computed property were broken
2016-03-03 14:45:53 -08:00
Chris Cowan
cbae3c0e1d
Fix T7183.
2016-03-03 12:15:11 -08:00
Chris Cowan
d864cde3c8
Add failing tests for T7183.
2016-03-03 12:12:14 -08:00
Logan Smyth
6ccd74a94e
Merge pull request #3395 from loganfsmyth/object-rest-binding
...
Recognize object rest properties as binding identifiers - fixes T7178
2016-03-03 09:44:51 -08:00
Logan Smyth
305252d335
Recognize object rest properties as binding identifiers - fixes T7178
2016-03-03 08:58:22 -08:00
Amjad Masad
47782a6170
Merge pull request #3389 from babel/block-binding-actual
...
Update scope binding info after transforming block-scoped bindings
2016-03-02 18:51:26 -08:00
Amjad Masad
3744aefb4f
Merge pull request #3391 from benjamn/fix-buildExportAll
...
Make buildExportAll generate pure ES5 code.
2016-03-02 18:50:47 -08:00
Henry Zhu
02a659a754
Merge pull request #3394 from babel/6.6.4-changelog
...
6.6.4 changelog [ci skip]
2016-03-02 16:49:19 -05:00
Henry Zhu
2aabefe812
6.6.4 changelog [ci skip]
2016-03-02 16:47:59 -05:00
Henry Zhu
39a8f5b796
v6.6.4
2016-03-02 16:29:17 -05:00
Henry Zhu
bca622abbc
Merge pull request #3388 from AgentME/dupgetters
...
Partial T7173 Fix: Prevent accessors being seen as duplicates of each other
2016-03-02 16:22:57 -05:00