Compare commits
12 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
658dde768e | ||
|
|
8df1d81ca4 | ||
|
|
a505e4a121 | ||
|
|
71eafdcac7 | ||
|
|
65060b0c97 | ||
|
|
09883962f1 | ||
|
|
1583262807 | ||
|
|
04c7cd5c0c | ||
|
|
3f6969f4f8 | ||
|
|
23db842cb8 | ||
|
|
41c82e00f9 | ||
|
|
766099e783 |
34
CHANGELOG.md
34
CHANGELOG.md
@@ -13,6 +13,40 @@ _Note: Gaps between patch versions are faulty/broken releases._
|
||||
|
||||
See [CHANGELOG - 6to5](CHANGELOG-6to5.md) for the pre-4.0.0 version changelog.
|
||||
|
||||
## 5.1.2
|
||||
|
||||
* **Bug Fix**
|
||||
* Add `getIterator` and `isIterable` to `babel-runtime` build script.
|
||||
|
||||
## 5.1.1
|
||||
|
||||
* **Bug Fix**
|
||||
* Add missing runtime symbol definitions.
|
||||
|
||||
## 5.1.0
|
||||
|
||||
* **Bug Fix**
|
||||
* Fix super reference when using decorators.
|
||||
* Don't do array unpack optimisation when member expressions are present.
|
||||
* Add missing descriptors for undecorated class properties.
|
||||
* Don't consider `arguments` and `eval` valid function names when doing function name inferrence.
|
||||
* Fix scope tracking of constants in loop heads.
|
||||
* Parse `AwaitExpression` as a unary instead of an assignment.
|
||||
* Fix regex evaluation when attempting static evaluation.
|
||||
* Don't emit tokens when doing a lookahead.
|
||||
* Add missing `test` declaration to `utility.deadCodeElimination` transformer.
|
||||
* **Internal**
|
||||
* Upgrade `regenerator` to the latest and use my branch with the hope of eventually switching to vanilla regenerator.
|
||||
* Add support for the replacement of for loop `init`s with statements.
|
||||
* Upgrade dependencies.
|
||||
* **Polish**
|
||||
* When adding the scope IIFE when using default parameters, don't shadow the function expression, just `apply` `this` and `arguments` if necessary.
|
||||
* Use path basename as non-default import fallback.
|
||||
* **New Feature**
|
||||
* Add [trailing function comma proposal](https://github.com/jeffmo/es-trailing-function-commas). Thanks [@AluisioASG](https://github.com/AluisioASG)!
|
||||
* Add support for object literal decorators.
|
||||
* Make core-js modular when using the `runtime` transformer.
|
||||
|
||||
## 5.0.12
|
||||
|
||||
* **Bug Fix**
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "babel-core",
|
||||
"description": "Turn ES6 code into readable vanilla ES5 with source maps",
|
||||
"version": "5.0.13",
|
||||
"version": "5.1.2",
|
||||
"author": "Sebastian McKenzie <sebmck@gmail.com>",
|
||||
"homepage": "https://babeljs.io/",
|
||||
"repository": "babel/babel",
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
{
|
||||
"name": "babel",
|
||||
"description": "Turn ES6 code into readable vanilla ES5 with source maps",
|
||||
"version": "5.0.12",
|
||||
"version": "5.1.1",
|
||||
"author": "Sebastian McKenzie <sebmck@gmail.com>",
|
||||
"homepage": "https://babeljs.io/",
|
||||
"repository": "babel/babel",
|
||||
"preferGlobal": true,
|
||||
"dependencies": {
|
||||
"babel-core": "^5.0.12",
|
||||
"babel-core": "^5.1.1",
|
||||
"chokidar": "^1.0.0",
|
||||
"commander": "^2.6.0",
|
||||
"fs-readdir-recursive": "^0.1.0",
|
||||
@@ -22,4 +22,4 @@
|
||||
"babel-node": "./bin/babel-node",
|
||||
"babel-external-helpers": "./bin/babel-external-helpers"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "babel-runtime",
|
||||
"description": "babel selfContained runtime",
|
||||
"version": "5.0.12",
|
||||
"version": "5.1.1",
|
||||
"repository": "babel/babel",
|
||||
"author": "Sebastian McKenzie <sebmck@gmail.com>",
|
||||
"dependencies": {
|
||||
|
||||
@@ -77,7 +77,7 @@ writeFile("regenerator/runtime.js", selfContainify(readFile("regenerator-babel/r
|
||||
|
||||
var coreDefinitions = require("../lib/babel/transformation/transformers/other/runtime/definitions");
|
||||
|
||||
var paths = [];
|
||||
var paths = ["is-iterable", "get-iterator"];
|
||||
|
||||
each(coreDefinitions.builtins, function (path) {
|
||||
paths.push(path);
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
"Set": "set",
|
||||
"WeakSet": "weak-set"
|
||||
},
|
||||
|
||||
"methods": {
|
||||
"Array": {
|
||||
"concat": "array/concat",
|
||||
@@ -94,6 +95,21 @@
|
||||
"addLocale": "date/add-locale",
|
||||
"formatUTC": "date/format-utc",
|
||||
"format": "date/format"
|
||||
},
|
||||
"Symbol": {
|
||||
"for": "symbol/for",
|
||||
"hasInstance": "symbol/for-instance",
|
||||
"is-concat-spreadable": "symbol/is-concat-spreadable",
|
||||
"iterator": "symbol/iterator",
|
||||
"keyFor": "symbol/key-for",
|
||||
"match": "symbol/match",
|
||||
"replace": "symbol/replace",
|
||||
"search": "symbol/search",
|
||||
"species": "symbol/species",
|
||||
"split": "symbol/split",
|
||||
"toPrimitive": "symbol/to-primitive",
|
||||
"toStringTag": "symbol/to-string-tag",
|
||||
"unscopables": "symbol/unscopables"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -51,7 +51,7 @@ var astVisitor = {
|
||||
var left = node.left;
|
||||
if (!isSymbolIterator(left)) return;
|
||||
|
||||
return t.callExpression(file.addImport(`${RUNTIME_MODULE_NAME}/core-js/is-iterator`, "isIterable", true), [node.right]);
|
||||
return t.callExpression(file.addImport(`${RUNTIME_MODULE_NAME}/core-js/is-iterable`, "isIterable", true), [node.right]);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
@@ -713,6 +713,11 @@ export default class TraversalPath {
|
||||
var search = [this.node];
|
||||
var i = 0;
|
||||
|
||||
function matches(name) {
|
||||
var part = parts[i];
|
||||
return part === "*" || name === part;
|
||||
}
|
||||
|
||||
while (search.length) {
|
||||
var node = search.shift();
|
||||
|
||||
@@ -722,10 +727,10 @@ export default class TraversalPath {
|
||||
|
||||
if (t.isIdentifier(node)) {
|
||||
// this part doesn't match
|
||||
if (parts[i] !== node.name) return false;
|
||||
if (!matches(node.name)) return false;
|
||||
} else if (t.isLiteral(node)) {
|
||||
// this part doesn't match
|
||||
if (parts[i] !== node.value) return false;
|
||||
if (!matches(node.value)) return false;
|
||||
} else if (t.isMemberExpression(node)) {
|
||||
if (node.computed && !t.isLiteral(node.property)) {
|
||||
// we can't deal with this
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
"use strict";
|
||||
|
||||
var _isIterable = require("babel-runtime/core-js/is-iterator")["default"];
|
||||
var _isIterable = require("babel-runtime/core-js/is-iterable")["default"];
|
||||
|
||||
_isIterable(Object(arr));
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
Symbol.iterator;
|
||||
@@ -0,0 +1,5 @@
|
||||
"use strict";
|
||||
|
||||
var _Symbol$iterator = require("babel-runtime/core-js/symbol/iterator")["default"];
|
||||
|
||||
_Symbol$iterator;
|
||||
Reference in New Issue
Block a user