TypeScript/tests/baselines/reference/collisionRestParameterUnderscoreIUsage.errors.txt
2014-07-12 17:30:19 -07:00

11 lines
469 B
Plaintext

==== tests/cases/compiler/collisionRestParameterUnderscoreIUsage.ts (1 errors) ====
declare var console: { log(msg?: string): void; };
var _i = "This is what I'd expect to see";
class Foo {
constructor(...args: any[]) {
console.log(_i); // This should result in error
~~
!!! Expression resolves to variable declaration '_i' that compiler uses to initialize rest parameter.
}
}
new Foo();