babel-source 5.8.34 → 5.8.35
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/lib/babel.js +162 -74
- data/lib/babel/source.rb +2 -2
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
NzY3NjJhNzEwYTY5MTgzZjcyZDcwMGNmMzYyYTRiZTgzNjk0ZjgwMA==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
MDdkYTg1OGFjNDJmNTE0M2M2ZGUzNWVkY2ZmYjBkNTNiN2ExNDgwZg==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
NjkwNTM0NDJhZDFjZjg0ZGY3YTAwZWJmYjNhNDQ5MDNhZGEyNDUwYTUyMzg2
|
10
|
+
NjJlZDBhNzZlNTcyYzA0NjIyZGQ0MmQ3YmZmMWRlNjNlNjNhMzgyMzZiMjA1
|
11
|
+
Y2I0OGE2NzViZjM3MGNmNTBhZDYyMGNmYjMwMWJkMThhY2MyZjk=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
NDljNGM3ZjJjMmZiNWRhZmM0NDNhNGFmZWJkY2ZlMDYwMDkwMzFmMWM2NDMy
|
14
|
+
M2UzZGQ1YThhYmY2YmMxMmM5NjBjMzBjYWEzNTFjMDJkZDQ0Zjk3ZTgzMTM1
|
15
|
+
Mjg1OGVmN2M3YTI1NmRhN2JkMjU3MWVjYjY1MzAyMjkyOTIyZjA=
|
data/lib/babel.js
CHANGED
@@ -372,6 +372,8 @@ var objectKeys = Object.keys || function (obj) {
|
|
372
372
|
*/
|
373
373
|
/* eslint-disable no-proto */
|
374
374
|
|
375
|
+
'use strict'
|
376
|
+
|
375
377
|
var base64 = _dereq_(4)
|
376
378
|
var ieee754 = _dereq_(5)
|
377
379
|
var isArray = _dereq_(6)
|
@@ -454,8 +456,10 @@ function Buffer (arg) {
|
|
454
456
|
return new Buffer(arg)
|
455
457
|
}
|
456
458
|
|
457
|
-
|
458
|
-
|
459
|
+
if (!Buffer.TYPED_ARRAY_SUPPORT) {
|
460
|
+
this.length = 0
|
461
|
+
this.parent = undefined
|
462
|
+
}
|
459
463
|
|
460
464
|
// Common case.
|
461
465
|
if (typeof arg === 'number') {
|
@@ -586,6 +590,10 @@ function fromJsonObject (that, object) {
|
|
586
590
|
if (Buffer.TYPED_ARRAY_SUPPORT) {
|
587
591
|
Buffer.prototype.__proto__ = Uint8Array.prototype
|
588
592
|
Buffer.__proto__ = Uint8Array
|
593
|
+
} else {
|
594
|
+
// pre-set for values that may exist in the future
|
595
|
+
Buffer.prototype.length = undefined
|
596
|
+
Buffer.prototype.parent = undefined
|
589
597
|
}
|
590
598
|
|
591
599
|
function allocate (that, length) {
|
@@ -736,10 +744,6 @@ function byteLength (string, encoding) {
|
|
736
744
|
}
|
737
745
|
Buffer.byteLength = byteLength
|
738
746
|
|
739
|
-
// pre-set for values that may exist in the future
|
740
|
-
Buffer.prototype.length = undefined
|
741
|
-
Buffer.prototype.parent = undefined
|
742
|
-
|
743
747
|
function slowToString (encoding, start, end) {
|
744
748
|
var loweredCase = false
|
745
749
|
|
@@ -1831,7 +1835,7 @@ function utf8ToBytes (string, units) {
|
|
1831
1835
|
}
|
1832
1836
|
|
1833
1837
|
// valid surrogate pair
|
1834
|
-
codePoint = leadSurrogate - 0xD800 << 10 | codePoint - 0xDC00
|
1838
|
+
codePoint = (leadSurrogate - 0xD800 << 10 | codePoint - 0xDC00) + 0x10000
|
1835
1839
|
} else if (leadSurrogate) {
|
1836
1840
|
// valid bmp char, but last char was a lead
|
1837
1841
|
if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD)
|
@@ -2123,38 +2127,10 @@ exports.write = function (buffer, value, offset, isLE, mLen, nBytes) {
|
|
2123
2127
|
}
|
2124
2128
|
|
2125
2129
|
},{}],6:[function(_dereq_,module,exports){
|
2130
|
+
var toString = {}.toString;
|
2126
2131
|
|
2127
|
-
|
2128
|
-
|
2129
|
-
*/
|
2130
|
-
|
2131
|
-
var isArray = Array.isArray;
|
2132
|
-
|
2133
|
-
/**
|
2134
|
-
* toString
|
2135
|
-
*/
|
2136
|
-
|
2137
|
-
var str = Object.prototype.toString;
|
2138
|
-
|
2139
|
-
/**
|
2140
|
-
* Whether or not the given `val`
|
2141
|
-
* is an array.
|
2142
|
-
*
|
2143
|
-
* example:
|
2144
|
-
*
|
2145
|
-
* isArray([]);
|
2146
|
-
* // > true
|
2147
|
-
* isArray(arguments);
|
2148
|
-
* // > false
|
2149
|
-
* isArray('');
|
2150
|
-
* // > false
|
2151
|
-
*
|
2152
|
-
* @param {mixed} val
|
2153
|
-
* @return {bool}
|
2154
|
-
*/
|
2155
|
-
|
2156
|
-
module.exports = isArray || function (val) {
|
2157
|
-
return !! val && '[object Array]' == str.call(val);
|
2132
|
+
module.exports = Array.isArray || function (arr) {
|
2133
|
+
return toString.call(arr) == '[object Array]';
|
2158
2134
|
};
|
2159
2135
|
|
2160
2136
|
},{}],7:[function(_dereq_,module,exports){
|
@@ -4415,7 +4391,9 @@ exports.BooleanTypeAnnotation = BooleanTypeAnnotation;
|
|
4415
4391
|
exports.BooleanLiteralTypeAnnotation = BooleanLiteralTypeAnnotation;
|
4416
4392
|
exports.DeclareClass = DeclareClass;
|
4417
4393
|
exports.DeclareFunction = DeclareFunction;
|
4394
|
+
exports.DeclareInterface = DeclareInterface;
|
4418
4395
|
exports.DeclareModule = DeclareModule;
|
4396
|
+
exports.DeclareTypeAlias = DeclareTypeAlias;
|
4419
4397
|
exports.DeclareVariable = DeclareVariable;
|
4420
4398
|
exports.FunctionTypeAnnotation = FunctionTypeAnnotation;
|
4421
4399
|
exports.FunctionTypeParam = FunctionTypeParam;
|
@@ -4425,9 +4403,11 @@ exports.InterfaceDeclaration = InterfaceDeclaration;
|
|
4425
4403
|
exports.IntersectionTypeAnnotation = IntersectionTypeAnnotation;
|
4426
4404
|
exports.MixedTypeAnnotation = MixedTypeAnnotation;
|
4427
4405
|
exports.NullableTypeAnnotation = NullableTypeAnnotation;
|
4406
|
+
exports.NullLiteralTypeAnnotation = NullLiteralTypeAnnotation;
|
4428
4407
|
exports.NumberTypeAnnotation = NumberTypeAnnotation;
|
4429
4408
|
exports.StringLiteralTypeAnnotation = StringLiteralTypeAnnotation;
|
4430
4409
|
exports.StringTypeAnnotation = StringTypeAnnotation;
|
4410
|
+
exports.ThisTypeAnnotation = ThisTypeAnnotation;
|
4431
4411
|
exports.TupleTypeAnnotation = TupleTypeAnnotation;
|
4432
4412
|
exports.TypeofTypeAnnotation = TypeofTypeAnnotation;
|
4433
4413
|
exports.TypeAlias = TypeAlias;
|
@@ -4503,6 +4483,15 @@ function DeclareFunction(node, print) {
|
|
4503
4483
|
this.semicolon();
|
4504
4484
|
}
|
4505
4485
|
|
4486
|
+
/**
|
4487
|
+
* Prints DeclareInterface.
|
4488
|
+
*/
|
4489
|
+
|
4490
|
+
function DeclareInterface(node, print) {
|
4491
|
+
this.push("declare ");
|
4492
|
+
this.InterfaceDeclaration(node, print);
|
4493
|
+
}
|
4494
|
+
|
4506
4495
|
/**
|
4507
4496
|
* Prints DeclareModule, prints id and body.
|
4508
4497
|
*/
|
@@ -4514,6 +4503,15 @@ function DeclareModule(node, print) {
|
|
4514
4503
|
print.plain(node.body);
|
4515
4504
|
}
|
4516
4505
|
|
4506
|
+
/**
|
4507
|
+
* Prints DeclareTypeAlias.
|
4508
|
+
*/
|
4509
|
+
|
4510
|
+
function DeclareTypeAlias(node, print) {
|
4511
|
+
this.push("declare ");
|
4512
|
+
this.TypeAlias(node, print);
|
4513
|
+
}
|
4514
|
+
|
4517
4515
|
/**
|
4518
4516
|
* Prints DeclareVariable, prints id and id.typeAnnotation.
|
4519
4517
|
*/
|
@@ -4597,6 +4595,10 @@ function _interfaceish(node, print) {
|
|
4597
4595
|
this.push(" extends ");
|
4598
4596
|
print.join(node["extends"], { separator: ", " });
|
4599
4597
|
}
|
4598
|
+
if (node.mixins && node.mixins.length) {
|
4599
|
+
this.push(" mixins ");
|
4600
|
+
print.join(node.mixins, { separator: ", " });
|
4601
|
+
}
|
4600
4602
|
this.space();
|
4601
4603
|
print.plain(node.body);
|
4602
4604
|
}
|
@@ -4635,6 +4637,14 @@ function NullableTypeAnnotation(node, print) {
|
|
4635
4637
|
print.plain(node.typeAnnotation);
|
4636
4638
|
}
|
4637
4639
|
|
4640
|
+
/**
|
4641
|
+
* Prints NullLiteralTypeAnnotation, prints value.
|
4642
|
+
*/
|
4643
|
+
|
4644
|
+
function NullLiteralTypeAnnotation() {
|
4645
|
+
this.push("null");
|
4646
|
+
}
|
4647
|
+
|
4638
4648
|
/**
|
4639
4649
|
* Prints NumberLiteralTypeAnnotation, prints value.
|
4640
4650
|
*/
|
@@ -4667,6 +4677,14 @@ function StringTypeAnnotation() {
|
|
4667
4677
|
this.push("string");
|
4668
4678
|
}
|
4669
4679
|
|
4680
|
+
/**
|
4681
|
+
* Prints ThisTypeAnnotation, prints this.
|
4682
|
+
*/
|
4683
|
+
|
4684
|
+
function ThisTypeAnnotation() {
|
4685
|
+
this.push("this");
|
4686
|
+
}
|
4687
|
+
|
4670
4688
|
/**
|
4671
4689
|
* Prints TupleTypeAnnotation, prints types.
|
4672
4690
|
*/
|
@@ -26478,7 +26496,7 @@ _index2["default"]("ClassBody", {
|
|
26478
26496
|
});
|
26479
26497
|
|
26480
26498
|
_index2["default"]("ClassDeclaration", {
|
26481
|
-
visitor: ["id", "body", "superClass", "typeParameters", "superTypeParameters", "implements", "decorators"],
|
26499
|
+
visitor: ["id", "body", "superClass", "mixins", "typeParameters", "superTypeParameters", "implements", "decorators"],
|
26482
26500
|
aliases: ["Scopable", "Class", "Statement", "Declaration"]
|
26483
26501
|
});
|
26484
26502
|
|
@@ -26680,11 +26698,21 @@ _index2["default"]("DeclareFunction", {
|
|
26680
26698
|
aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"]
|
26681
26699
|
});
|
26682
26700
|
|
26701
|
+
_index2["default"]("DeclareInterface", {
|
26702
|
+
visitor: ["id", "typeParameters", "extends", "body"],
|
26703
|
+
aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"]
|
26704
|
+
});
|
26705
|
+
|
26683
26706
|
_index2["default"]("DeclareModule", {
|
26684
26707
|
visitor: ["id", "body"],
|
26685
26708
|
aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"]
|
26686
26709
|
});
|
26687
26710
|
|
26711
|
+
_index2["default"]("DeclareTypeAlias", {
|
26712
|
+
visitor: ["id", "typeParameters", "right"],
|
26713
|
+
aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"]
|
26714
|
+
});
|
26715
|
+
|
26688
26716
|
_index2["default"]("DeclareVariable", {
|
26689
26717
|
visitor: ["id"],
|
26690
26718
|
aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"]
|
@@ -26729,6 +26757,10 @@ _index2["default"]("NullableTypeAnnotation", {
|
|
26729
26757
|
aliases: ["Flow"]
|
26730
26758
|
});
|
26731
26759
|
|
26760
|
+
_index2["default"]("NullLiteralTypeAnnotation", {
|
26761
|
+
aliases: ["Flow"]
|
26762
|
+
});
|
26763
|
+
|
26732
26764
|
_index2["default"]("NumberLiteralTypeAnnotation", {
|
26733
26765
|
aliases: ["Flow"]
|
26734
26766
|
});
|
@@ -26745,6 +26777,10 @@ _index2["default"]("StringTypeAnnotation", {
|
|
26745
26777
|
aliases: ["Flow", "FlowBaseAnnotation"]
|
26746
26778
|
});
|
26747
26779
|
|
26780
|
+
_index2["default"]("ThisTypeAnnotation", {
|
26781
|
+
aliases: ["Flow", "FlowBaseAnnotation"]
|
26782
|
+
});
|
26783
|
+
|
26748
26784
|
_index2["default"]("TupleTypeAnnotation", {
|
26749
26785
|
visitor: ["types"],
|
26750
26786
|
aliases: ["Flow"]
|
@@ -29545,7 +29581,7 @@ module.exports = function (str) {
|
|
29545
29581
|
throw new TypeError('Expected a string');
|
29546
29582
|
}
|
29547
29583
|
|
29548
|
-
return str.replace(matchOperatorsRe,
|
29584
|
+
return str.replace(matchOperatorsRe, '\\$&');
|
29549
29585
|
};
|
29550
29586
|
|
29551
29587
|
},{}],203:[function(_dereq_,module,exports){
|
@@ -29632,7 +29668,8 @@ var path = _dereq_(9);
|
|
29632
29668
|
|
29633
29669
|
var commentRx = /^\s*\/(?:\/|\*)[@#]\s+sourceMappingURL=data:(?:application|text)\/json;(?:charset[:=]\S+;)?base64,(.*)$/mg;
|
29634
29670
|
var mapFileCommentRx =
|
29635
|
-
//
|
29671
|
+
//Example (Extra space between slashes added to solve Safari bug. Exclude space in production):
|
29672
|
+
// / /# sourceMappingURL=foo.js.map
|
29636
29673
|
/(?:\/\/[@#][ \t]+sourceMappingURL=([^\s'"]+?)[ \t]*$)|(?:\/\*[@#][ \t]+sourceMappingURL=([^\*]+?)[ \t]*(?:\*\/){1}[ \t]*$)/mg
|
29637
29674
|
|
29638
29675
|
function decodeBase64(base64) {
|
@@ -41593,41 +41630,53 @@ function expand(str, isTop) {
|
|
41593
41630
|
},{"532":532,"533":533}],532:[function(_dereq_,module,exports){
|
41594
41631
|
module.exports = balanced;
|
41595
41632
|
function balanced(a, b, str) {
|
41596
|
-
var
|
41597
|
-
|
41598
|
-
|
41633
|
+
var r = range(a, b, str);
|
41634
|
+
|
41635
|
+
return r && {
|
41636
|
+
start: r[0],
|
41637
|
+
end: r[1],
|
41638
|
+
pre: str.slice(0, r[0]),
|
41639
|
+
body: str.slice(r[0] + a.length, r[1]),
|
41640
|
+
post: str.slice(r[1] + b.length)
|
41641
|
+
};
|
41642
|
+
}
|
41599
41643
|
|
41600
|
-
|
41601
|
-
|
41602
|
-
|
41603
|
-
|
41604
|
-
|
41605
|
-
|
41606
|
-
|
41607
|
-
|
41608
|
-
|
41609
|
-
|
41610
|
-
|
41611
|
-
|
41612
|
-
|
41613
|
-
|
41614
|
-
|
41615
|
-
|
41644
|
+
balanced.range = range;
|
41645
|
+
function range(a, b, str) {
|
41646
|
+
var begs, beg, left, right, result;
|
41647
|
+
var ai = str.indexOf(a);
|
41648
|
+
var bi = str.indexOf(b, ai + 1);
|
41649
|
+
var i = ai;
|
41650
|
+
|
41651
|
+
if (ai >= 0 && bi > 0) {
|
41652
|
+
begs = [];
|
41653
|
+
left = str.length;
|
41654
|
+
|
41655
|
+
while (i < str.length && i >= 0 && ! result) {
|
41656
|
+
if (i == ai) {
|
41657
|
+
begs.push(i);
|
41658
|
+
ai = str.indexOf(a, i + 1);
|
41659
|
+
} else if (begs.length == 1) {
|
41660
|
+
result = [ begs.pop(), bi ];
|
41661
|
+
} else {
|
41662
|
+
beg = begs.pop();
|
41663
|
+
if (beg < left) {
|
41664
|
+
left = beg;
|
41665
|
+
right = bi;
|
41666
|
+
}
|
41667
|
+
|
41668
|
+
bi = str.indexOf(b, i + 1);
|
41616
41669
|
}
|
41670
|
+
|
41671
|
+
i = ai < bi && ai >= 0 ? ai : bi;
|
41617
41672
|
}
|
41618
|
-
}
|
41619
41673
|
|
41620
|
-
|
41621
|
-
|
41622
|
-
var start = m.start + a.length;
|
41623
|
-
m = balanced(a, b, str.substr(start));
|
41624
|
-
if (m) {
|
41625
|
-
m.start += start;
|
41626
|
-
m.end += start;
|
41627
|
-
m.pre = str.slice(0, start) + m.pre;
|
41674
|
+
if (begs.length) {
|
41675
|
+
result = [ left, right ];
|
41628
41676
|
}
|
41629
|
-
return m;
|
41630
41677
|
}
|
41678
|
+
|
41679
|
+
return result;
|
41631
41680
|
}
|
41632
41681
|
|
41633
41682
|
},{}],533:[function(_dereq_,module,exports){
|
@@ -61775,7 +61824,7 @@ resolve.relative = function (loc) {
|
|
61775
61824
|
},{"1":1,"10":10}],611:[function(_dereq_,module,exports){
|
61776
61825
|
module.exports={
|
61777
61826
|
"name": "babel-core",
|
61778
|
-
"version": "5.8.
|
61827
|
+
"version": "5.8.35",
|
61779
61828
|
"description": "A compiler for writing next generation JavaScript",
|
61780
61829
|
"author": "Sebastian McKenzie <sebmck@gmail.com>",
|
61781
61830
|
"homepage": "https://babeljs.io/",
|
@@ -61817,7 +61866,7 @@ module.exports={
|
|
61817
61866
|
"babel-plugin-runtime": "^1.0.7",
|
61818
61867
|
"babel-plugin-undeclared-variables-check": "^1.0.2",
|
61819
61868
|
"babel-plugin-undefined-to-void": "^1.1.6",
|
61820
|
-
"babylon": "^5.8.
|
61869
|
+
"babylon": "^5.8.35",
|
61821
61870
|
"bluebird": "^2.9.33",
|
61822
61871
|
"chalk": "^1.0.0",
|
61823
61872
|
"convert-source-map": "^1.1.0",
|
@@ -64075,7 +64124,7 @@ pp.parseExportDeclaration = function () {
|
|
64075
64124
|
|
64076
64125
|
pp.isExportDefaultSpecifier = function () {
|
64077
64126
|
if (this.match(_tokenizerTypes.types.name)) {
|
64078
|
-
return this.state.value !== "type" && this.state.value !== "async";
|
64127
|
+
return this.state.value !== "type" && this.state.value !== "async" && this.state.value !== "interface";
|
64079
64128
|
}
|
64080
64129
|
|
64081
64130
|
if (!this.match(_tokenizerTypes.types._default)) {
|
@@ -64365,6 +64414,10 @@ pp.flowParseDeclare = function (node) {
|
|
64365
64414
|
return this.flowParseDeclareVariable(node);
|
64366
64415
|
} else if (this.isContextual("module")) {
|
64367
64416
|
return this.flowParseDeclareModule(node);
|
64417
|
+
} else if (this.isContextual("type")) {
|
64418
|
+
return this.flowParseDeclareTypeAlias(node);
|
64419
|
+
} else if (this.isContextual("interface")) {
|
64420
|
+
return this.flowParseDeclareInterface(node);
|
64368
64421
|
} else {
|
64369
64422
|
this.unexpected();
|
64370
64423
|
}
|
@@ -64403,6 +64456,18 @@ pp.flowParseDeclareModule = function (node) {
|
|
64403
64456
|
return this.finishNode(node, "DeclareModule");
|
64404
64457
|
};
|
64405
64458
|
|
64459
|
+
pp.flowParseDeclareTypeAlias = function (node) {
|
64460
|
+
this.next();
|
64461
|
+
this.flowParseTypeAlias(node);
|
64462
|
+
return this.finishNode(node, "DeclareTypeAlias");
|
64463
|
+
};
|
64464
|
+
|
64465
|
+
pp.flowParseDeclareInterface = function (node) {
|
64466
|
+
this.next();
|
64467
|
+
this.flowParseInterfaceish(node);
|
64468
|
+
return this.finishNode(node, "DeclareInterface");
|
64469
|
+
};
|
64470
|
+
|
64406
64471
|
// Interfaces
|
64407
64472
|
|
64408
64473
|
pp.flowParseInterfaceish = function (node, allowStatic) {
|
@@ -64415,6 +64480,7 @@ pp.flowParseInterfaceish = function (node, allowStatic) {
|
|
64415
64480
|
}
|
64416
64481
|
|
64417
64482
|
node["extends"] = [];
|
64483
|
+
node.mixins = [];
|
64418
64484
|
|
64419
64485
|
if (this.eat(_tokenizerTypes.types._extends)) {
|
64420
64486
|
do {
|
@@ -64422,6 +64488,13 @@ pp.flowParseInterfaceish = function (node, allowStatic) {
|
|
64422
64488
|
} while (this.eat(_tokenizerTypes.types.comma));
|
64423
64489
|
}
|
64424
64490
|
|
64491
|
+
if (this.isContextual("mixins")) {
|
64492
|
+
this.next();
|
64493
|
+
do {
|
64494
|
+
node.mixins.push(this.flowParseInterfaceExtends());
|
64495
|
+
} while (this.eat(_tokenizerTypes.types.comma));
|
64496
|
+
}
|
64497
|
+
|
64425
64498
|
node.body = this.flowParseObjectType(allowStatic);
|
64426
64499
|
};
|
64427
64500
|
|
@@ -64806,6 +64879,16 @@ pp.flowParsePrimaryType = function () {
|
|
64806
64879
|
this.next();
|
64807
64880
|
return this.finishNode(node, "NumberLiteralTypeAnnotation");
|
64808
64881
|
|
64882
|
+
case _tokenizerTypes.types._null:
|
64883
|
+
node.value = this.match(_tokenizerTypes.types._null);
|
64884
|
+
this.next();
|
64885
|
+
return this.finishNode(node, "NullLiteralTypeAnnotation");
|
64886
|
+
|
64887
|
+
case _tokenizerTypes.types._this:
|
64888
|
+
node.value = this.match(_tokenizerTypes.types._this);
|
64889
|
+
this.next();
|
64890
|
+
return this.finishNode(node, "ThisTypeAnnotation");
|
64891
|
+
|
64809
64892
|
default:
|
64810
64893
|
if (this.state.type.keyword === "typeof") {
|
64811
64894
|
return this.flowParseTypeofType();
|
@@ -64942,7 +65025,7 @@ exports["default"] = function (instance) {
|
|
64942
65025
|
|
64943
65026
|
instance.extend("shouldParseExportDeclaration", function (inner) {
|
64944
65027
|
return function () {
|
64945
|
-
return this.isContextual("type") || inner.call(this);
|
65028
|
+
return this.isContextual("type") || this.isContextual("interface") || inner.call(this);
|
64946
65029
|
};
|
64947
65030
|
});
|
64948
65031
|
|
@@ -64998,6 +65081,11 @@ exports["default"] = function (instance) {
|
|
64998
65081
|
// export type Foo = Bar;
|
64999
65082
|
return this.flowParseTypeAlias(declarationNode);
|
65000
65083
|
}
|
65084
|
+
} else if (this.isContextual("interface")) {
|
65085
|
+
node.exportKind = "type";
|
65086
|
+
var _declarationNode = this.startNode();
|
65087
|
+
this.next();
|
65088
|
+
return this.flowParseInterface(_declarationNode);
|
65001
65089
|
} else {
|
65002
65090
|
return inner.call(this, node);
|
65003
65091
|
}
|
data/lib/babel/source.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: babel-source
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 5.8.
|
4
|
+
version: 5.8.35
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sebastian McKenzie
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2016-01-20 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description:
|
14
14
|
email: sebmck@gmail.com
|