Update Baselines

This commit is contained in:
Yui T
2015-03-16 14:28:29 -07:00
parent 0eeb7ce7b8
commit 2c7ea7f6b2
66 changed files with 261 additions and 459 deletions

View File

@@ -1,4 +1,4 @@
tests/cases/conformance/es6/computedProperties/computedPropertyNames24_ES5.ts(9,6): error TS2466: 'super' cannot be referenced in a computed property name.
tests/cases/conformance/es6/computedProperties/computedPropertyNames24_ES5.ts(7,6): error TS2466: 'super' cannot be referenced in a computed property name.
==== tests/cases/conformance/es6/computedProperties/computedPropertyNames24_ES5.ts (1 errors) ====
@@ -8,8 +8,6 @@ tests/cases/conformance/es6/computedProperties/computedPropertyNames24_ES5.ts(9,
}
}
class C extends Base {
// Gets emitted as super, not _super, which is consistent with
// use of super in static properties initializers.
[super.bar()]() { }
~~~~~
!!! error TS2466: 'super' cannot be referenced in a computed property name.

View File

@@ -5,8 +5,6 @@ class Base {
}
}
class C extends Base {
// Gets emitted as super, not _super, which is consistent with
// use of super in static properties initializers.
[super.bar()]() { }
}
@@ -30,9 +28,7 @@ var C = (function (_super) {
function C() {
_super.apply(this, arguments);
}
// Gets emitted as super, not _super, which is consistent with
// use of super in static properties initializers.
C.prototype[super.bar.call(this)] = function () {
C.prototype[_super.bar.call(this)] = function () {
};
return C;
})(Base);

View File

@@ -1,4 +1,4 @@
tests/cases/conformance/es6/computedProperties/computedPropertyNames26_ES5.ts(10,12): error TS2466: 'super' cannot be referenced in a computed property name.
tests/cases/conformance/es6/computedProperties/computedPropertyNames26_ES5.ts(8,12): error TS2466: 'super' cannot be referenced in a computed property name.
==== tests/cases/conformance/es6/computedProperties/computedPropertyNames26_ES5.ts (1 errors) ====
@@ -8,8 +8,6 @@ tests/cases/conformance/es6/computedProperties/computedPropertyNames26_ES5.ts(10
}
}
class C extends Base {
// Gets emitted as super, not _super, which is consistent with
// use of super in static properties initializers.
[
{ [super.bar()]: 1 }[0]
~~~~~

View File

@@ -5,8 +5,6 @@ class Base {
}
}
class C extends Base {
// Gets emitted as super, not _super, which is consistent with
// use of super in static properties initializers.
[
{ [super.bar()]: 1 }[0]
]() { }
@@ -32,10 +30,8 @@ var C = (function (_super) {
function C() {
_super.apply(this, arguments);
}
// Gets emitted as super, not _super, which is consistent with
// use of super in static properties initializers.
C.prototype[(_a = {},
_a[super.bar.call(this)] = 1,
_a[_super.bar.call(this)] = 1,
_a)[0]] = function () {
};
return C;

View File

@@ -1,2 +1,2 @@
//// [computedPropertyNamesSourceMap1_ES5.js.map]
{"version":3,"file":"computedPropertyNamesSourceMap1_ES5.js","sourceRoot":"","sources":["computedPropertyNamesSourceMap1_ES5.ts"],"names":["C","C.constructor","C[\"hello\"]"],"mappings":"AAAA;IAAAA;IAIAC,CAACA;IAHGD,YAACA,OAAOA;QACJE,QAAQA,CAACA;IACbA,CAACA;IACLF,QAACA;AAADA,CAACA,AAJD,IAIC"}
{"version":3,"file":"computedPropertyNamesSourceMap1_ES5.js","sourceRoot":"","sources":["computedPropertyNamesSourceMap1_ES5.ts"],"names":["C","C.constructor","C[\"hello\"]"],"mappings":"AAAA;IAAAA;IAIAC,CAACA;IAHGD,YAACA,OAAOA,CAACA,GAATA;QACIE,QAAQA,CAACA;IACbA,CAACA;IACLF,QAACA;AAADA,CAACA,AAJD,IAIC"}

View File

@@ -37,18 +37,24 @@ sourceFile:computedPropertyNamesSourceMap1_ES5.ts
1->^^^^
2 > ^^^^^^^^^^^^
3 > ^^^^^^^
4 > ^
5 > ^^^
1->
2 > [
3 > "hello"
4 > ]
5 >
1->Emitted(4, 5) Source(2, 5) + SourceIndex(0) name (C)
2 >Emitted(4, 17) Source(2, 6) + SourceIndex(0) name (C)
3 >Emitted(4, 24) Source(2, 13) + SourceIndex(0) name (C)
4 >Emitted(4, 25) Source(2, 14) + SourceIndex(0) name (C)
5 >Emitted(4, 28) Source(2, 5) + SourceIndex(0) name (C)
---
>>> debugger;
1 >^^^^^^^^
2 > ^^^^^^^^
3 > ^
1 >]() {
1 >["hello"]() {
>
2 > debugger
3 > ;

View File

@@ -1,2 +1,2 @@
//// [computedPropertyNamesSourceMap1_ES6.js.map]
{"version":3,"file":"computedPropertyNamesSourceMap1_ES6.js","sourceRoot":"","sources":["computedPropertyNamesSourceMap1_ES6.ts"],"names":["C","C[\"hello\"]"],"mappings":"AAAA;IACIA,CAACA,OAAOA;QACJC,QAAQA,CAACA;IACbA,CAACA;AACLD,CAACA;AAAA"}
{"version":3,"file":"computedPropertyNamesSourceMap1_ES6.js","sourceRoot":"","sources":["computedPropertyNamesSourceMap1_ES6.ts"],"names":["C","C[\"hello\"]"],"mappings":"AAAA;IACIA,CAACA,OAAOA,CAACA;QACLC,QAAQA,CAACA;IACbA,CAACA;AACLD,CAACA;AAAA"}

View File

@@ -18,20 +18,23 @@ sourceFile:computedPropertyNamesSourceMap1_ES6.ts
1->^^^^
2 > ^
3 > ^^^^^^^
4 > ^^^^^^->
4 > ^
5 > ^^^^^->
1->class C {
>
2 > [
3 > "hello"
4 > ]
1->Emitted(2, 5) Source(2, 5) + SourceIndex(0) name (C)
2 >Emitted(2, 6) Source(2, 6) + SourceIndex(0) name (C)
3 >Emitted(2, 13) Source(2, 13) + SourceIndex(0) name (C)
4 >Emitted(2, 14) Source(2, 14) + SourceIndex(0) name (C)
---
>>> debugger;
1->^^^^^^^^
2 > ^^^^^^^^
3 > ^
1->]() {
1->() {
>
2 > debugger
3 > ;

View File

@@ -12,8 +12,6 @@ class C {
//// [computedPropertyNamesWithStaticProperty.js]
class C {
constructor() {
}
get [C.staticProp]() {
return "hello";
}

View File

@@ -1,16 +0,0 @@
tests/cases/conformance/es6/classDeclaration/emitClassDeclarationWithExport.ts(1,14): error TS1148: Cannot compile external modules unless the '--module' flag is provided.
tests/cases/conformance/es6/classDeclaration/emitClassDeclarationWithExport.ts(5,22): error TS2309: An export assignment cannot be used in a module with other exported elements.
==== tests/cases/conformance/es6/classDeclaration/emitClassDeclarationWithExport.ts (2 errors) ====
export class C {
~
!!! error TS1148: Cannot compile external modules unless the '--module' flag is provided.
foo() { }
}
export default class D {
~
!!! error TS2309: An export assignment cannot be used in a module with other exported elements.
bar() { }
}

View File

@@ -1,23 +0,0 @@
//// [emitClassDeclarationWithExport.ts]
export class C {
foo() { }
}
export default class D {
bar() { }
}
//// [emitClassDeclarationWithExport.js]
export class C {
constructor() {
}
foo() {
}
}
export default class D {
constructor() {
}
bar() {
}
}
module.exports = D;

View File

@@ -11,8 +11,6 @@ class D {
//// [emitClassDeclarationWithStaticPropertyAssignmentInES6.js]
class C {
constructor() {
}
}
C.z = "Foo";
class D {

View File

@@ -49,20 +49,20 @@ var RegisteredUser = (function (_super) {
RegisteredUser.prototype.f = function () {
(function () {
function inner() {
super.sayHello.call(this);
_super.sayHello.call(this);
}
});
};
RegisteredUser.prototype.g = function () {
function inner() {
(function () {
super.sayHello.call(this);
_super.sayHello.call(this);
});
}
};
RegisteredUser.prototype.h = function () {
function inner() {
super.sayHello.call(this);
_super.sayHello.call(this);
}
};
return RegisteredUser;

View File

@@ -140,27 +140,27 @@ var __extends = this.__extends || function (d, b) {
//super property access in instance member accessor(get and set) of class with no base type
var NoBase = (function () {
function NoBase() {
this.m = super.prototype;
this.n = super.hasOwnProperty.call(this, '');
var a = super.prototype;
var b = super.hasOwnProperty.call(this, '');
this.m = _super.prototype;
this.n = _super.hasOwnProperty.call(this, '');
var a = _super.prototype;
var b = _super.hasOwnProperty.call(this, '');
}
NoBase.prototype.fn = function () {
var a = super.prototype;
var b = super.hasOwnProperty.call(this, '');
var a = _super.prototype;
var b = _super.hasOwnProperty.call(this, '');
};
//super static property access in static member function of class with no base type
//super static property access in static member accessor(get and set) of class with no base type
NoBase.static1 = function () {
super.hasOwnProperty.call(this, '');
_super.hasOwnProperty.call(this, '');
};
Object.defineProperty(NoBase, "static2", {
get: function () {
super.hasOwnProperty.call(this, '');
_super.hasOwnProperty.call(this, '');
return '';
},
set: function (n) {
super.hasOwnProperty.call(this, '');
_super.hasOwnProperty.call(this, '');
},
enumerable: true,
configurable: true
@@ -210,11 +210,11 @@ var SomeDerived1 = (function (_super) {
});
SomeDerived1.prototype.fn2 = function () {
function inner() {
super.publicFunc.call(this);
_super.publicFunc.call(this);
}
var x = {
test: function () {
return super.publicFunc.call(this);
return _super.publicFunc.call(this);
}
};
};
@@ -278,6 +278,6 @@ var SomeDerived3 = (function (_super) {
})(SomeBase);
// In object literal
var obj = {
n: super.wat,
p: super.foo.call(this)
n: _super.wat,
p: _super.foo.call(this)
};

View File

@@ -14,14 +14,13 @@ class A
}
//// [es6-amd.js]
var A = (function () {
function A() {
class A {
constructor() {
}
A.prototype.B = function () {
B() {
return 42;
};
return A;
})();
}
}
//# sourceMappingURL=es6-amd.js.map
//// [es6-amd.d.ts]

View File

@@ -1,2 +1,2 @@
//// [es6-amd.js.map]
{"version":3,"file":"es6-amd.js","sourceRoot":"","sources":["es6-amd.ts"],"names":["A","A.constructor","A.B"],"mappings":"AACA;IAEIA;IAGAC,CAACA;IAEMD,aAACA,GAARA;QAEIE,MAAMA,CAACA,EAAEA,CAACA;IACdA,CAACA;IACLF,QAACA;AAADA,CAACA,AAXD,IAWC"}
{"version":3,"file":"es6-amd.js","sourceRoot":"","sources":["es6-amd.ts"],"names":["A","A.constructor","A.B"],"mappings":"AACA;IAEIA;IAGAC,CAACA;IAEMD,CAACA;QAEJE,MAAMA,CAACA,EAAEA,CAACA;IACdA,CAACA;AACLF,CAACA;AAAA"}

View File

@@ -8,14 +8,14 @@ sources: es6-amd.ts
emittedFile:tests/cases/compiler/es6-amd.js
sourceFile:es6-amd.ts
-------------------------------------------------------------------
>>>var A = (function () {
>>>class A {
1 >
2 >^^^^^^^^^^^^^^^^^^^->
2 >^^^^^^^^^^^^^^^^^^^^->
1 >
>
1 >Emitted(1, 1) Source(2, 1) + SourceIndex(0)
---
>>> function A() {
>>> constructor() {
1->^^^^
2 > ^^->
1->class A
@@ -26,7 +26,7 @@ sourceFile:es6-amd.ts
>>> }
1->^^^^
2 > ^
3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
3 > ^^^^^->
1->constructor ()
> {
>
@@ -35,81 +35,57 @@ sourceFile:es6-amd.ts
1->Emitted(3, 5) Source(7, 5) + SourceIndex(0) name (A.constructor)
2 >Emitted(3, 6) Source(7, 6) + SourceIndex(0) name (A.constructor)
---
>>> A.prototype.B = function () {
>>> B() {
1->^^^^
2 > ^^^^^^^^^^^^^
3 > ^^^
2 > ^
3 > ^^^^^^^^^^^^^^->
1->
>
> public
2 > B
3 >
1->Emitted(4, 5) Source(9, 12) + SourceIndex(0) name (A)
2 >Emitted(4, 18) Source(9, 13) + SourceIndex(0) name (A)
3 >Emitted(4, 21) Source(9, 5) + SourceIndex(0) name (A)
2 >Emitted(4, 6) Source(9, 13) + SourceIndex(0) name (A)
---
>>> return 42;
1 >^^^^^^^^
1->^^^^^^^^
2 > ^^^^^^
3 > ^
4 > ^^
5 > ^
1 >public B()
1->()
> {
>
2 > return
3 >
4 > 42
5 > ;
1 >Emitted(5, 9) Source(11, 9) + SourceIndex(0) name (A.B)
1->Emitted(5, 9) Source(11, 9) + SourceIndex(0) name (A.B)
2 >Emitted(5, 15) Source(11, 15) + SourceIndex(0) name (A.B)
3 >Emitted(5, 16) Source(11, 16) + SourceIndex(0) name (A.B)
4 >Emitted(5, 18) Source(11, 18) + SourceIndex(0) name (A.B)
5 >Emitted(5, 19) Source(11, 19) + SourceIndex(0) name (A.B)
---
>>> };
>>> }
1 >^^^^
2 > ^
3 > ^^^^^^^^^->
1 >
>
2 > }
1 >Emitted(6, 5) Source(12, 5) + SourceIndex(0) name (A.B)
2 >Emitted(6, 6) Source(12, 6) + SourceIndex(0) name (A.B)
---
>>> return A;
1->^^^^
2 > ^^^^^^^^
1->
>
2 > }
1->Emitted(7, 5) Source(13, 1) + SourceIndex(0) name (A)
2 >Emitted(7, 13) Source(13, 2) + SourceIndex(0) name (A)
---
>>>})();
>>>}
1 >
2 >^
3 >
4 > ^^^^
5 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
1 >
3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
1 >
>
2 >}
3 >
4 > class A
> {
> constructor ()
> {
>
> }
>
> public B()
> {
> return 42;
> }
> }
1 >Emitted(8, 1) Source(13, 1) + SourceIndex(0) name (A)
2 >Emitted(8, 2) Source(13, 2) + SourceIndex(0) name (A)
3 >Emitted(8, 2) Source(2, 1) + SourceIndex(0)
4 >Emitted(8, 6) Source(13, 2) + SourceIndex(0)
1 >Emitted(7, 1) Source(13, 1) + SourceIndex(0) name (A)
2 >Emitted(7, 2) Source(13, 2) + SourceIndex(0) name (A)
---
>>>//# sourceMappingURL=es6-amd.js.map
>>>//# sourceMappingURL=es6-amd.js.map1->
2 >^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
1->
1->Emitted(8, 1) Source(13, 2) + SourceIndex(0)
---

View File

@@ -14,14 +14,13 @@ class A
}
//// [es6-declaration-amd.js]
var A = (function () {
function A() {
class A {
constructor() {
}
A.prototype.B = function () {
B() {
return 42;
};
return A;
})();
}
}
//# sourceMappingURL=es6-declaration-amd.js.map
//// [es6-declaration-amd.d.ts]

View File

@@ -1,2 +1,2 @@
//// [es6-declaration-amd.js.map]
{"version":3,"file":"es6-declaration-amd.js","sourceRoot":"","sources":["es6-declaration-amd.ts"],"names":["A","A.constructor","A.B"],"mappings":"AACA;IAEIA;IAGAC,CAACA;IAEMD,aAACA,GAARA;QAEIE,MAAMA,CAACA,EAAEA,CAACA;IACdA,CAACA;IACLF,QAACA;AAADA,CAACA,AAXD,IAWC"}
{"version":3,"file":"es6-declaration-amd.js","sourceRoot":"","sources":["es6-declaration-amd.ts"],"names":["A","A.constructor","A.B"],"mappings":"AACA;IAEIA;IAGAC,CAACA;IAEMD,CAACA;QAEJE,MAAMA,CAACA,EAAEA,CAACA;IACdA,CAACA;AACLF,CAACA;AAAA"}

View File

@@ -8,14 +8,14 @@ sources: es6-declaration-amd.ts
emittedFile:tests/cases/compiler/es6-declaration-amd.js
sourceFile:es6-declaration-amd.ts
-------------------------------------------------------------------
>>>var A = (function () {
>>>class A {
1 >
2 >^^^^^^^^^^^^^^^^^^^->
2 >^^^^^^^^^^^^^^^^^^^^->
1 >
>
1 >Emitted(1, 1) Source(2, 1) + SourceIndex(0)
---
>>> function A() {
>>> constructor() {
1->^^^^
2 > ^^->
1->class A
@@ -26,7 +26,7 @@ sourceFile:es6-declaration-amd.ts
>>> }
1->^^^^
2 > ^
3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
3 > ^^^^^->
1->constructor ()
> {
>
@@ -35,81 +35,57 @@ sourceFile:es6-declaration-amd.ts
1->Emitted(3, 5) Source(7, 5) + SourceIndex(0) name (A.constructor)
2 >Emitted(3, 6) Source(7, 6) + SourceIndex(0) name (A.constructor)
---
>>> A.prototype.B = function () {
>>> B() {
1->^^^^
2 > ^^^^^^^^^^^^^
3 > ^^^
2 > ^
3 > ^^^^^^^^^^^^^^->
1->
>
> public
2 > B
3 >
1->Emitted(4, 5) Source(9, 12) + SourceIndex(0) name (A)
2 >Emitted(4, 18) Source(9, 13) + SourceIndex(0) name (A)
3 >Emitted(4, 21) Source(9, 5) + SourceIndex(0) name (A)
2 >Emitted(4, 6) Source(9, 13) + SourceIndex(0) name (A)
---
>>> return 42;
1 >^^^^^^^^
1->^^^^^^^^
2 > ^^^^^^
3 > ^
4 > ^^
5 > ^
1 >public B()
1->()
> {
>
2 > return
3 >
4 > 42
5 > ;
1 >Emitted(5, 9) Source(11, 9) + SourceIndex(0) name (A.B)
1->Emitted(5, 9) Source(11, 9) + SourceIndex(0) name (A.B)
2 >Emitted(5, 15) Source(11, 15) + SourceIndex(0) name (A.B)
3 >Emitted(5, 16) Source(11, 16) + SourceIndex(0) name (A.B)
4 >Emitted(5, 18) Source(11, 18) + SourceIndex(0) name (A.B)
5 >Emitted(5, 19) Source(11, 19) + SourceIndex(0) name (A.B)
---
>>> };
>>> }
1 >^^^^
2 > ^
3 > ^^^^^^^^^->
1 >
>
2 > }
1 >Emitted(6, 5) Source(12, 5) + SourceIndex(0) name (A.B)
2 >Emitted(6, 6) Source(12, 6) + SourceIndex(0) name (A.B)
---
>>> return A;
1->^^^^
2 > ^^^^^^^^
1->
>
2 > }
1->Emitted(7, 5) Source(13, 1) + SourceIndex(0) name (A)
2 >Emitted(7, 13) Source(13, 2) + SourceIndex(0) name (A)
---
>>>})();
>>>}
1 >
2 >^
3 >
4 > ^^^^
5 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
1 >
3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
1 >
>
2 >}
3 >
4 > class A
> {
> constructor ()
> {
>
> }
>
> public B()
> {
> return 42;
> }
> }
1 >Emitted(8, 1) Source(13, 1) + SourceIndex(0) name (A)
2 >Emitted(8, 2) Source(13, 2) + SourceIndex(0) name (A)
3 >Emitted(8, 2) Source(2, 1) + SourceIndex(0)
4 >Emitted(8, 6) Source(13, 2) + SourceIndex(0)
1 >Emitted(7, 1) Source(13, 1) + SourceIndex(0) name (A)
2 >Emitted(7, 2) Source(13, 2) + SourceIndex(0) name (A)
---
>>>//# sourceMappingURL=es6-declaration-amd.js.map
>>>//# sourceMappingURL=es6-declaration-amd.js.map1->
2 >^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
1->
1->Emitted(8, 1) Source(13, 2) + SourceIndex(0)
---

View File

@@ -14,12 +14,11 @@ class A
}
//// [es6-sourcemap-amd.js]
var A = (function () {
function A() {
class A {
constructor() {
}
A.prototype.B = function () {
B() {
return 42;
};
return A;
})();
}
}
//# sourceMappingURL=es6-sourcemap-amd.js.map

View File

@@ -1,2 +1,2 @@
//// [es6-sourcemap-amd.js.map]
{"version":3,"file":"es6-sourcemap-amd.js","sourceRoot":"","sources":["es6-sourcemap-amd.ts"],"names":["A","A.constructor","A.B"],"mappings":"AACA;IAEIA;IAGAC,CAACA;IAEMD,aAACA,GAARA;QAEIE,MAAMA,CAACA,EAAEA,CAACA;IACdA,CAACA;IACLF,QAACA;AAADA,CAACA,AAXD,IAWC"}
{"version":3,"file":"es6-sourcemap-amd.js","sourceRoot":"","sources":["es6-sourcemap-amd.ts"],"names":["A","A.constructor","A.B"],"mappings":"AACA;IAEIA;IAGAC,CAACA;IAEMD,CAACA;QAEJE,MAAMA,CAACA,EAAEA,CAACA;IACdA,CAACA;AACLF,CAACA;AAAA"}

View File

@@ -8,14 +8,14 @@ sources: es6-sourcemap-amd.ts
emittedFile:tests/cases/compiler/es6-sourcemap-amd.js
sourceFile:es6-sourcemap-amd.ts
-------------------------------------------------------------------
>>>var A = (function () {
>>>class A {
1 >
2 >^^^^^^^^^^^^^^^^^^^->
2 >^^^^^^^^^^^^^^^^^^^^->
1 >
>
1 >Emitted(1, 1) Source(2, 1) + SourceIndex(0)
---
>>> function A() {
>>> constructor() {
1->^^^^
2 > ^^->
1->class A
@@ -26,7 +26,7 @@ sourceFile:es6-sourcemap-amd.ts
>>> }
1->^^^^
2 > ^
3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
3 > ^^^^^->
1->constructor ()
> {
>
@@ -35,81 +35,57 @@ sourceFile:es6-sourcemap-amd.ts
1->Emitted(3, 5) Source(7, 5) + SourceIndex(0) name (A.constructor)
2 >Emitted(3, 6) Source(7, 6) + SourceIndex(0) name (A.constructor)
---
>>> A.prototype.B = function () {
>>> B() {
1->^^^^
2 > ^^^^^^^^^^^^^
3 > ^^^
2 > ^
3 > ^^^^^^^^^^^^^^->
1->
>
> public
2 > B
3 >
1->Emitted(4, 5) Source(9, 12) + SourceIndex(0) name (A)
2 >Emitted(4, 18) Source(9, 13) + SourceIndex(0) name (A)
3 >Emitted(4, 21) Source(9, 5) + SourceIndex(0) name (A)
2 >Emitted(4, 6) Source(9, 13) + SourceIndex(0) name (A)
---
>>> return 42;
1 >^^^^^^^^
1->^^^^^^^^
2 > ^^^^^^
3 > ^
4 > ^^
5 > ^
1 >public B()
1->()
> {
>
2 > return
3 >
4 > 42
5 > ;
1 >Emitted(5, 9) Source(11, 9) + SourceIndex(0) name (A.B)
1->Emitted(5, 9) Source(11, 9) + SourceIndex(0) name (A.B)
2 >Emitted(5, 15) Source(11, 15) + SourceIndex(0) name (A.B)
3 >Emitted(5, 16) Source(11, 16) + SourceIndex(0) name (A.B)
4 >Emitted(5, 18) Source(11, 18) + SourceIndex(0) name (A.B)
5 >Emitted(5, 19) Source(11, 19) + SourceIndex(0) name (A.B)
---
>>> };
>>> }
1 >^^^^
2 > ^
3 > ^^^^^^^^^->
1 >
>
2 > }
1 >Emitted(6, 5) Source(12, 5) + SourceIndex(0) name (A.B)
2 >Emitted(6, 6) Source(12, 6) + SourceIndex(0) name (A.B)
---
>>> return A;
1->^^^^
2 > ^^^^^^^^
1->
>
2 > }
1->Emitted(7, 5) Source(13, 1) + SourceIndex(0) name (A)
2 >Emitted(7, 13) Source(13, 2) + SourceIndex(0) name (A)
---
>>>})();
>>>}
1 >
2 >^
3 >
4 > ^^^^
5 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
1 >
3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
1 >
>
2 >}
3 >
4 > class A
> {
> constructor ()
> {
>
> }
>
> public B()
> {
> return 42;
> }
> }
1 >Emitted(8, 1) Source(13, 1) + SourceIndex(0) name (A)
2 >Emitted(8, 2) Source(13, 2) + SourceIndex(0) name (A)
3 >Emitted(8, 2) Source(2, 1) + SourceIndex(0)
4 >Emitted(8, 6) Source(13, 2) + SourceIndex(0)
1 >Emitted(7, 1) Source(13, 1) + SourceIndex(0) name (A)
2 >Emitted(7, 2) Source(13, 2) + SourceIndex(0) name (A)
---
>>>//# sourceMappingURL=es6-sourcemap-amd.js.map
>>>//# sourceMappingURL=es6-sourcemap-amd.js.map1->
2 >^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^->
1->
1->Emitted(8, 1) Source(13, 2) + SourceIndex(0)
---

View File

@@ -259,30 +259,25 @@ var m;
lable: let l2 = 0;
})(m || (m = {}));
// methods
var C = (function () {
function C() {
class C {
constructor() {
let l = 0;
n = l;
}
C.prototype.method = function () {
method() {
let l = 0;
n = l;
};
Object.defineProperty(C.prototype, "v", {
get: function () {
let l = 0;
n = l;
return n;
},
set: function (value) {
let l = 0;
n = l;
},
enumerable: true,
configurable: true
});
return C;
})();
}
get v() {
let l = 0;
n = l;
return n;
}
set v(value) {
let l = 0;
n = l;
}
}
// object literals
var o = {
f() {

View File

@@ -221,26 +221,21 @@ var m;
}
})(m || (m = {}));
// methods
var C = (function () {
function C() {
class C {
constructor() {
let l24 = 0;
}
C.prototype.method = function () {
method() {
let l25 = 0;
};
Object.defineProperty(C.prototype, "v", {
get: function () {
let l26 = 0;
return l26;
},
set: function (value) {
let l27 = value;
},
enumerable: true,
configurable: true
});
return C;
})();
}
get v() {
let l26 = 0;
return l26;
}
set v(value) {
let l27 = value;
}
}
// object literals
var o = {
f() {

View File

@@ -1,5 +1,3 @@
tests/cases/conformance/es6/classDeclaration/parseClassDeclarationInStrictModeByDefaultInES6.ts(2,5): error TS1100: Invalid use of 'interface' in strict mode.
tests/cases/conformance/es6/classDeclaration/parseClassDeclarationInStrictModeByDefaultInES6.ts(3,12): error TS1100: Invalid use of 'implements' in strict mode.
tests/cases/conformance/es6/classDeclaration/parseClassDeclarationInStrictModeByDefaultInES6.ts(4,16): error TS1100: Invalid use of 'arguments' in strict mode.
tests/cases/conformance/es6/classDeclaration/parseClassDeclarationInStrictModeByDefaultInES6.ts(5,17): error TS1100: Invalid use of 'eval' in strict mode.
tests/cases/conformance/es6/classDeclaration/parseClassDeclarationInStrictModeByDefaultInES6.ts(6,9): error TS1100: Invalid use of 'arguments' in strict mode.
@@ -7,14 +5,10 @@ tests/cases/conformance/es6/classDeclaration/parseClassDeclarationInStrictModeBy
Property 'callee' is missing in type 'String'.
==== tests/cases/conformance/es6/classDeclaration/parseClassDeclarationInStrictModeByDefaultInES6.ts (6 errors) ====
==== tests/cases/conformance/es6/classDeclaration/parseClassDeclarationInStrictModeByDefaultInES6.ts (4 errors) ====
class C {
interface = 10;
~~~~~~~~~
!!! error TS1100: Invalid use of 'interface' in strict mode.
public implements() { }
~~~~~~~~~~
!!! error TS1100: Invalid use of 'implements' in strict mode.
public foo(arguments: any) { }
~~~~~~~~~
!!! error TS1100: Invalid use of 'arguments' in strict mode.

View File

@@ -4,9 +4,8 @@ class C {
}
//// [parserComputedPropertyName10.js]
var C = (function () {
function C() {
class C {
constructor() {
this[e] = 1;
}
return C;
})();
}

View File

@@ -4,8 +4,5 @@ class C {
}
//// [parserComputedPropertyName11.js]
var C = (function () {
function C() {
}
return C;
})();
class C {
}

View File

@@ -4,10 +4,7 @@ class C {
}
//// [parserComputedPropertyName12.js]
var C = (function () {
function C() {
class C {
[e]() {
}
C.prototype[e] = function () {
};
return C;
})();
}

View File

@@ -4,14 +4,7 @@ class C {
}
//// [parserComputedPropertyName24.js]
var C = (function () {
function C() {
class C {
set [e](v) {
}
Object.defineProperty(C.prototype, e, {
set: function (v) {
},
enumerable: true,
configurable: true
});
return C;
})();
}

View File

@@ -6,10 +6,9 @@ class C {
}
//// [parserComputedPropertyName25.js]
var C = (function () {
function C() {
class C {
constructor() {
// No ASI
this[e] = 0[e2] = 1;
}
return C;
})();
}

View File

@@ -6,10 +6,9 @@ class C {
}
//// [parserComputedPropertyName27.js]
var C = (function () {
function C() {
class C {
constructor() {
// No ASI
this[e] = 0[e2];
}
return C;
})();
}

View File

@@ -5,9 +5,8 @@ class C {
}
//// [parserComputedPropertyName28.js]
var C = (function () {
function C() {
class C {
constructor() {
this[e] = 0;
}
return C;
})();
}

View File

@@ -6,10 +6,9 @@ class C {
}
//// [parserComputedPropertyName29.js]
var C = (function () {
function C() {
class C {
constructor() {
// yes ASI
this[e] = id++;
}
return C;
})();
}

View File

@@ -6,8 +6,5 @@ class C {
}
//// [parserComputedPropertyName31.js]
var C = (function () {
function C() {
}
return C;
})();
class C {
}

View File

@@ -6,12 +6,11 @@ class C {
}
//// [parserComputedPropertyName33.js]
var C = (function () {
function C() {
class C {
constructor() {
// No ASI
this[e] = 0[e2]();
}
return C;
})();
}
{
}

View File

@@ -1,12 +1,15 @@
tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName36.ts(2,5): error TS1166: A computed property name in a class property declaration must directly refer to a built-in symbol.
tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName36.ts(2,6): error TS2304: Cannot find name 'public'.
tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName36.ts(2,6): error TS1109: Expression expected.
tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName36.ts(2,13): error TS1068: Unexpected token. A constructor, method, accessor, or property was expected.
tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName36.ts(2,14): error TS1068: Unexpected token. A constructor, method, accessor, or property was expected.
==== tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName36.ts (2 errors) ====
==== tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName36.ts (3 errors) ====
class C {
[public ]: string;
~~~~~~~~~
!!! error TS1166: A computed property name in a class property declaration must directly refer to a built-in symbol.
~~~~~~
!!! error TS2304: Cannot find name 'public'.
!!! error TS1109: Expression expected.
~
!!! error TS1068: Unexpected token. A constructor, method, accessor, or property was expected.
~
!!! error TS1068: Unexpected token. A constructor, method, accessor, or property was expected.
}

View File

@@ -4,8 +4,5 @@ class C {
}
//// [parserComputedPropertyName36.js]
var C = (function () {
function C() {
}
return C;
})();
class C {
}

View File

@@ -1,9 +1,21 @@
tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName38.ts(2,6): error TS2304: Cannot find name 'public'.
tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName38.ts(2,6): error TS1109: Expression expected.
tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName38.ts(2,12): error TS1068: Unexpected token. A constructor, method, accessor, or property was expected.
tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName38.ts(2,13): error TS1068: Unexpected token. A constructor, method, accessor, or property was expected.
tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName38.ts(2,16): error TS1005: '=>' expected.
tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName38.ts(3,1): error TS1128: Declaration or statement expected.
==== tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName38.ts (1 errors) ====
==== tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName38.ts (5 errors) ====
class C {
[public]() { }
~~~~~~
!!! error TS2304: Cannot find name 'public'.
}
!!! error TS1109: Expression expected.
~
!!! error TS1068: Unexpected token. A constructor, method, accessor, or property was expected.
~
!!! error TS1068: Unexpected token. A constructor, method, accessor, or property was expected.
~
!!! error TS1005: '=>' expected.
}
~
!!! error TS1128: Declaration or statement expected.

View File

@@ -4,10 +4,7 @@ class C {
}
//// [parserComputedPropertyName38.js]
var C = (function () {
function C() {
}
C.prototype[public] = function () {
};
return C;
})();
class C {
}
(() => {
});

View File

@@ -6,10 +6,7 @@ class C {
//// [parserComputedPropertyName39.js]
"use strict";
var C = (function () {
function C() {
}
return C;
})();
class C {
}
(() => {
});

View File

@@ -4,10 +4,7 @@ class C {
}
//// [parserComputedPropertyName40.js]
var C = (function () {
function C() {
class C {
[a ? "" : ""]() {
}
C.prototype[a ? "" : ""] = function () {
};
return C;
})();
}

View File

@@ -4,8 +4,5 @@ class C {
}
//// [parserComputedPropertyName7.js]
var C = (function () {
function C() {
}
return C;
})();
class C {
}

View File

@@ -4,8 +4,5 @@ class C {
}
//// [parserComputedPropertyName8.js]
var C = (function () {
function C() {
}
return C;
})();
class C {
}

View File

@@ -4,8 +4,5 @@ class C {
}
//// [parserComputedPropertyName9.js]
var C = (function () {
function C() {
}
return C;
})();
class C {
}

View File

@@ -18,7 +18,7 @@ var C = (function () {
function C() {
}
C.prototype.foo = function () {
super.foo.call(this);
_super.foo.call(this);
};
return C;
})();
@@ -30,7 +30,7 @@ var M1;
function C() {
}
C.prototype.foo = function () {
super.foo.call(this);
_super.foo.call(this);
};
return C;
})();

View File

@@ -10,7 +10,7 @@ var C = (function () {
function C() {
}
C.prototype.M = function () {
super..call(this, 0);
_super..call(this, 0);
};
return C;
})();

View File

@@ -18,7 +18,7 @@ var C = (function () {
function C() {
}
C.prototype.foo = function () {
super.foo = 1;
_super.foo = 1;
};
return C;
})();
@@ -30,7 +30,7 @@ var M1;
function C() {
}
C.prototype.foo = function () {
super.foo = 1;
_super.foo = 1;
};
return C;
})();

View File

@@ -4,8 +4,5 @@ class C {
}
//// [parserSymbolIndexer2.js]
var C = (function () {
function C() {
}
return C;
})();
class C {
}

View File

@@ -4,8 +4,5 @@ class C {
}
//// [parserSymbolIndexer3.js]
var C = (function () {
function C() {
}
return C;
})();
class C {
}

View File

@@ -4,8 +4,5 @@ class C {
}
//// [parserSymbolProperty5.js]
var C = (function () {
function C() {
}
return C;
})();
class C {
}

View File

@@ -4,9 +4,8 @@ class C {
}
//// [parserSymbolProperty6.js]
var C = (function () {
function C() {
class C {
constructor() {
this[Symbol.toStringTag] = "";
}
return C;
})();
}

View File

@@ -4,10 +4,7 @@ class C {
}
//// [parserSymbolProperty7.js]
var C = (function () {
function C() {
class C {
[Symbol.toStringTag]() {
}
C.prototype[Symbol.toStringTag] = function () {
};
return C;
})();
}

View File

@@ -1,2 +1,2 @@
//// [properties.js.map]
{"version":3,"file":"properties.js","sourceRoot":"","sources":["properties.ts"],"names":["MyClass","MyClass.constructor","MyClass.Count"],"mappings":"AACA;IAAAA;IAWAC,CAACA;IATGD,sBAAWA,0BAAKA;aAAhBA;YAEIE,MAAMA,CAACA,EAAEA,CAACA;QACdA,CAACA;aAEDF,UAAiBA,KAAaA;YAE1BE,EAAEA;QACNA,CAACA;;;OALAF;IAMLA,cAACA;AAADA,CAACA,AAXD,IAWC"}
{"version":3,"file":"properties.js","sourceRoot":"","sources":["properties.ts"],"names":["MyClass","MyClass.constructor","MyClass.Count"],"mappings":"AACA;IAAAA;IAWAC,CAACA;IATcD,gDAAKA;aAAhBA;YAEIE,MAAMA,CAACA,EAAEA,CAACA;QACdA,CAACA;aAEDF,UAAiBA,KAAaA;YAE1BE,EAAEA;QACNA,CAACA;;;OALAF;IAMLA,cAACA;AAADA,CAACA,AAXD,IAWC"}

View File

@@ -43,14 +43,11 @@ sourceFile:properties.ts
---
>>> Object.defineProperty(MyClass.prototype, "Count", {
1->^^^^
2 > ^^^^^^^^^^^^^^^^^^^^^^
3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^
2 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1->
2 > public get
3 > Count
1->Emitted(4, 5) Source(4, 5) + SourceIndex(0) name (MyClass)
2 >Emitted(4, 27) Source(4, 16) + SourceIndex(0) name (MyClass)
3 >Emitted(4, 53) Source(4, 21) + SourceIndex(0) name (MyClass)
2 > Count
1->Emitted(4, 5) Source(4, 16) + SourceIndex(0) name (MyClass)
2 >Emitted(4, 53) Source(4, 21) + SourceIndex(0) name (MyClass)
---
>>> get: function () {
1 >^^^^^^^^^^^^^

View File

@@ -1,2 +1,2 @@
//// [sourceMapValidationClass.js.map]
{"version":3,"file":"sourceMapValidationClass.js","sourceRoot":"","sources":["sourceMapValidationClass.ts"],"names":["Greeter","Greeter.constructor","Greeter.greet","Greeter.fn","Greeter.greetings"],"mappings":"AAAA;IACIA,iBAAmBA,QAAgBA;QAAEC,WAAcA;aAAdA,WAAcA,CAAdA,sBAAcA,CAAdA,IAAcA;YAAdA,0BAAcA;;QAAhCA,aAAQA,GAARA,QAAQA,CAAQA;QAM3BA,OAAEA,GAAWA,EAAEA,CAACA;IALxBA,CAACA;IACDD,uBAAKA,GAALA;QACIE,MAAMA,CAACA,MAAMA,GAAGA,IAAIA,CAACA,QAAQA,GAAGA,OAAOA,CAACA;IAC5CA,CAACA;IAGOF,oBAAEA,GAAVA;QACIG,MAAMA,CAACA,IAAIA,CAACA,QAAQA,CAACA;IACzBA,CAACA;IACDH,sBAAIA,8BAASA;aAAbA;YACII,MAAMA,CAACA,IAAIA,CAACA,QAAQA,CAACA;QACzBA,CAACA;aACDJ,UAAcA,SAAiBA;YAC3BI,IAAIA,CAACA,QAAQA,GAAGA,SAASA,CAACA;QAC9BA,CAACA;;;OAHAJ;IAILA,cAACA;AAADA,CAACA,AAjBD,IAiBC"}
{"version":3,"file":"sourceMapValidationClass.js","sourceRoot":"","sources":["sourceMapValidationClass.ts"],"names":["Greeter","Greeter.constructor","Greeter.greet","Greeter.fn","Greeter.greetings"],"mappings":"AAAA;IACIA,iBAAmBA,QAAgBA;QAAEC,WAAcA;aAAdA,WAAcA,CAAdA,sBAAcA,CAAdA,IAAcA;YAAdA,0BAAcA;;QAAhCA,aAAQA,GAARA,QAAQA,CAAQA;QAM3BA,OAAEA,GAAWA,EAAEA,CAACA;IALxBA,CAACA;IACDD,uBAAKA,GAALA;QACIE,MAAMA,CAACA,MAAMA,GAAGA,IAAIA,CAACA,QAAQA,GAAGA,OAAOA,CAACA;IAC5CA,CAACA;IAGOF,oBAAEA,GAAVA;QACIG,MAAMA,CAACA,IAAIA,CAACA,QAAQA,CAACA;IACzBA,CAACA;IACGH,oDAASA;aAAbA;YACII,MAAMA,CAACA,IAAIA,CAACA,QAAQA,CAACA;QACzBA,CAACA;aACDJ,UAAcA,SAAiBA;YAC3BI,IAAIA,CAACA,QAAQA,GAAGA,SAASA,CAACA;QAC9BA,CAACA;;;OAHAJ;IAILA,cAACA;AAADA,CAACA,AAjBD,IAiBC"}

View File

@@ -223,15 +223,12 @@ sourceFile:sourceMapValidationClass.ts
---
>>> Object.defineProperty(Greeter.prototype, "greetings", {
1->^^^^
2 > ^^^^^^^^^^^^^^^^^^^^^^
3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1->
>
2 > get
3 > greetings
1->Emitted(16, 5) Source(12, 5) + SourceIndex(0) name (Greeter)
2 >Emitted(16, 27) Source(12, 9) + SourceIndex(0) name (Greeter)
3 >Emitted(16, 57) Source(12, 18) + SourceIndex(0) name (Greeter)
> get
2 > greetings
1->Emitted(16, 5) Source(12, 9) + SourceIndex(0) name (Greeter)
2 >Emitted(16, 57) Source(12, 18) + SourceIndex(0) name (Greeter)
---
>>> get: function () {
1 >^^^^^^^^^^^^^

View File

@@ -80,7 +80,7 @@ var Base2 = (function () {
function Base2() {
}
Base2.prototype.foo = function () {
super.foo.call(this);
_super.foo.call(this);
};
return Base2;
})();

View File

@@ -166,7 +166,7 @@ var Base4;
function Sub4E() {
}
Sub4E.prototype.x = function () {
return super.x.call(this);
return _super.x.call(this);
};
return Sub4E;
})();

View File

@@ -64,6 +64,6 @@ var Q = (function (_super) {
_super.x.call(this); // error
_super.y.call(this);
};
Q.yy = super.; // error for static initializer accessing super
Q.yy = _super.; // error for static initializer accessing super
return Q;
})(P);

View File

@@ -60,14 +60,14 @@ var __extends = this.__extends || function (d, b) {
};
function foo() {
// super in a non class context
var x = super.;
var x = _super.;
var y = function () {
return super.;
return _super.;
};
var z = function () {
return function () {
return function () {
return super.;
return _super.;
};
};
};
@@ -88,18 +88,18 @@ var RegisteredUser = (function (_super) {
this.name = "Frank";
// super call in an inner function in a constructor
function inner() {
super.sayHello.call(this);
_super.sayHello.call(this);
}
// super call in a lambda in an inner function in a constructor
function inner2() {
var x = function () {
return super.sayHello.call(this);
return _super.sayHello.call(this);
};
}
// super call in a lambda in a function expression in a constructor
(function () {
return function () {
return super.;
return _super.;
};
})();
}
@@ -109,13 +109,13 @@ var RegisteredUser = (function (_super) {
// super call in a lambda in an inner function in a method
function inner() {
var x = function () {
return super.sayHello.call(this);
return _super.sayHello.call(this);
};
}
// super call in a lambda in a function expression in a constructor
(function () {
return function () {
return super.;
return _super.;
};
})();
};

View File

@@ -39,13 +39,13 @@ var ObjectLiteral;
var ThisInObjectLiteral = {
_foo: '1',
get foo() {
return super._foo;
return _super._foo;
},
set foo(value) {
super._foo = value;
_super._foo = value;
},
test: function () {
return super._foo;
return _super._foo;
}
};
})(ObjectLiteral || (ObjectLiteral = {}));
@@ -65,7 +65,7 @@ var SuperObjectTest = (function (_super) {
SuperObjectTest.prototype.testing = function () {
var test = {
get F() {
return super.test.call(this);
return _super.test.call(this);
}
};
};

View File

@@ -8,8 +8,6 @@ class C {
//// [symbolDeclarationEmit11.js]
class C {
constructor() {
}
static [Symbol.toPrimitive]() {
}
static get [Symbol.isRegExp]() {

View File

@@ -1,8 +0,0 @@
// @target: es6
export class C {
foo(y: string, ...args: any) { }
}
export default class D {
bar(k = 10) {}
}

View File

@@ -5,7 +5,5 @@ class Base {
}
}
class C extends Base {
// Gets emitted as super, not _super, which is consistent with
// use of super in static properties initializers.
[super.bar()]() { }
}

View File

@@ -5,8 +5,6 @@ class Base {
}
}
class C extends Base {
// Gets emitted as super, not _super, which is consistent with
// use of super in static properties initializers.
[
{ [super.bar()]: 1 }[0]
]() { }