TypeScript/tests/baselines/reference/collisionThisExpressionAndLocalVarInFunction.errors.txt
2014-09-12 13:35:07 -07:00

13 lines
567 B
Plaintext

tests/cases/compiler/collisionThisExpressionAndLocalVarInFunction.ts(5,9): error TS2399: Duplicate identifier '_this'. Compiler uses variable declaration '_this' to capture 'this' reference.
==== tests/cases/compiler/collisionThisExpressionAndLocalVarInFunction.ts (1 errors) ====
var console: {
log(val: any);
}
function x() {
var _this = 5;
~~~~~
!!! error TS2399: Duplicate identifier '_this'. Compiler uses variable declaration '_this' to capture 'this' reference.
x => { console.log(this.x); };
}