1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
|
=== tests/cases/compiler/collisionSuperAndNameResolution.ts ===
var console: {
>console : Symbol(console, Decl(collisionSuperAndNameResolution.ts, 0, 3))
log(message: any);
>log : Symbol(log, Decl(collisionSuperAndNameResolution.ts, 0, 14))
>message : Symbol(message, Decl(collisionSuperAndNameResolution.ts, 1, 8))
}
var _super = 10; // No error
>_super : Symbol(_super, Decl(collisionSuperAndNameResolution.ts, 3, 3))
class base {
>base : Symbol(base, Decl(collisionSuperAndNameResolution.ts, 3, 16))
}
class Foo extends base {
>Foo : Symbol(Foo, Decl(collisionSuperAndNameResolution.ts, 5, 1))
>base : Symbol(base, Decl(collisionSuperAndNameResolution.ts, 3, 16))
x() {
>x : Symbol(Foo.x, Decl(collisionSuperAndNameResolution.ts, 6, 24))
console.log(_super); // Error as this doesnt not resolve to user defined _super
>console.log : Symbol(log, Decl(collisionSuperAndNameResolution.ts, 0, 14))
>console : Symbol(console, Decl(collisionSuperAndNameResolution.ts, 0, 3))
>log : Symbol(log, Decl(collisionSuperAndNameResolution.ts, 0, 14))
>_super : Symbol(_super, Decl(collisionSuperAndNameResolution.ts, 3, 3))
}
}
|