TypeScript/tests/baselines/reference/emitRestParametersMethodES6.js
2015-02-06 18:45:09 -08:00

32 lines
675 B
JavaScript

//// [emitRestParametersMethodES6.ts]
class C {
constructor(name: string, ...rest) { }
public bar(...rest) { }
public foo(x: number, ...rest) { }
}
class D {
constructor(...rest) { }
public bar(...rest) { }
public foo(x: number, ...rest) { }
}
//// [emitRestParametersMethodES6.js]
var C = (function () {
function C(name, ...rest) {
}
C.prototype.bar = function (...rest) { };
C.prototype.foo = function (x, ...rest) { };
return C;
})();
var D = (function () {
function D(...rest) {
}
D.prototype.bar = function (...rest) { };
D.prototype.foo = function (x, ...rest) { };
return D;
})();