TypeScript/tests/cases/compiler/thisInConstructorParameter2.ts

11 lines
235 B
TypeScript
Raw Normal View History

2014-07-13 01:04:16 +02:00
class P {
x = this;
static y = this;
constructor(public z = this, zz = this, zzz = (p = this) => this) {
zzz = (p = this) => this;
}
2014-07-13 01:04:16 +02:00
foo(zz = this) { zz.x; }
static bar(zz = this) { zz.y; }
}