added new strict mode test

This commit is contained in:
Vladimir Matveev 2014-07-17 18:32:26 -07:00
parent 4068404cd4
commit 52ab9f110e
2 changed files with 64 additions and 0 deletions

View file

@ -0,0 +1,46 @@
//// [strictMode5.ts]
function foo(...args) {
"use strict"
}
class A {
m() {
"use strict"
var v = () => {
return this.n();
};
}
n() {}
}
function bar(x: number = 10) {
"use strict"
}
//// [strictMode5.js]
function foo() {
var args = [];
for (var _i = 0; _i < arguments.length; _i++) {
args[_i - 0] = arguments[_i];
}
"use strict";
}
var A = (function () {
function A() {
}
A.prototype.m = function () {
var _this = this;
"use strict";
var v = function () {
return _this.n();
};
};
A.prototype.n = function () {
};
return A;
})();
function bar(x) {
if (x === void 0) { x = 10; }
"use strict";
}

View file

@ -0,0 +1,18 @@
function foo(...args) {
"use strict"
}
class A {
m() {
"use strict"
var v = () => {
return this.n();
};
}
n() {}
}
function bar(x: number = 10) {
"use strict"
}