TypeScript/tests/baselines/reference/varBlock.errors.txt
Cyrus Najmabadi f1a2e41a8a Sort diagnostics in our baseline output.
This was we don't get noisy baselines just because a different phase of the compiler reported
the diagnostic.

This helps with Yui's refactoring work to move grammar checks into the type checker.
2014-12-16 15:56:56 -08:00

102 lines
5.1 KiB
Plaintext

tests/cases/compiler/varBlock.ts(8,16): error TS1039: Initializers are not allowed in ambient contexts.
tests/cases/compiler/varBlock.ts(11,22): error TS2369: A parameter property is only allowed in a constructor implementation.
tests/cases/compiler/varBlock.ts(11,22): error TS2371: A parameter initializer is only allowed in a function or constructor implementation.
tests/cases/compiler/varBlock.ts(15,15): error TS1039: Initializers are not allowed in ambient contexts.
tests/cases/compiler/varBlock.ts(21,16): error TS1039: Initializers are not allowed in ambient contexts.
tests/cases/compiler/varBlock.ts(22,20): error TS1039: Initializers are not allowed in ambient contexts.
tests/cases/compiler/varBlock.ts(25,19): error TS1039: Initializers are not allowed in ambient contexts.
tests/cases/compiler/varBlock.ts(26,24): error TS1039: Initializers are not allowed in ambient contexts.
tests/cases/compiler/varBlock.ts(26,33): error TS1039: Initializers are not allowed in ambient contexts.
tests/cases/compiler/varBlock.ts(27,27): error TS1039: Initializers are not allowed in ambient contexts.
tests/cases/compiler/varBlock.ts(28,33): error TS1039: Initializers are not allowed in ambient contexts.
tests/cases/compiler/varBlock.ts(28,43): error TS1039: Initializers are not allowed in ambient contexts.
tests/cases/compiler/varBlock.ts(32,11): error TS1039: Initializers are not allowed in ambient contexts.
tests/cases/compiler/varBlock.ts(33,16): error TS1039: Initializers are not allowed in ambient contexts.
tests/cases/compiler/varBlock.ts(33,25): error TS1039: Initializers are not allowed in ambient contexts.
tests/cases/compiler/varBlock.ts(34,19): error TS1039: Initializers are not allowed in ambient contexts.
tests/cases/compiler/varBlock.ts(35,25): error TS1039: Initializers are not allowed in ambient contexts.
tests/cases/compiler/varBlock.ts(35,35): error TS1039: Initializers are not allowed in ambient contexts.
tests/cases/compiler/varBlock.ts(39,13): error TS2403: Subsequent variable declarations must have the same type. Variable 'c' must be of type 'any', but here has type 'number'.
tests/cases/compiler/varBlock.ts(39,15): error TS1039: Initializers are not allowed in ambient contexts.
==== tests/cases/compiler/varBlock.ts (20 errors) ====
module m2 {
export var a, b2: number = 10, b;
}
declare module m3 {
var a, b, c;
var a1, b1 = 10;
~
!!! error TS1039: Initializers are not allowed in ambient contexts.
class C {
constructor (public c = 10);
~~~~~~~~~~~~~
!!! error TS2369: A parameter property is only allowed in a constructor implementation.
~~~~~~~~~~~~~
!!! error TS2371: A parameter initializer is only allowed in a function or constructor implementation.
}
}
declare var b = 10;
~
!!! error TS1039: Initializers are not allowed in ambient contexts.
declare var a2, b2, c2;
declare var da = 10;
~
!!! error TS1039: Initializers are not allowed in ambient contexts.
declare var d3, d4 = 10;
~
!!! error TS1039: Initializers are not allowed in ambient contexts.
module m3 {
declare var d = 10;
~
!!! error TS1039: Initializers are not allowed in ambient contexts.
declare var d2, d3 = 10, d4 = 10;
~
!!! error TS1039: Initializers are not allowed in ambient contexts.
~
!!! error TS1039: Initializers are not allowed in ambient contexts.
export declare var dE = 10;
~
!!! error TS1039: Initializers are not allowed in ambient contexts.
export declare var d2E, d3E = 10, d4E = 10;
~
!!! error TS1039: Initializers are not allowed in ambient contexts.
~
!!! error TS1039: Initializers are not allowed in ambient contexts.
}
declare module m4 {
var d = 10;
~
!!! error TS1039: Initializers are not allowed in ambient contexts.
var d2, d3 = 10, d4 =10;
~
!!! error TS1039: Initializers are not allowed in ambient contexts.
~
!!! error TS1039: Initializers are not allowed in ambient contexts.
export var dE = 10;
~
!!! error TS1039: Initializers are not allowed in ambient contexts.
export var d2E, d3E = 10, d4E = 10;
~
!!! error TS1039: Initializers are not allowed in ambient contexts.
~
!!! error TS1039: Initializers are not allowed in ambient contexts.
}
declare var c;
declare var c = 10;
~
!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'c' must be of type 'any', but here has type 'number'.
~
!!! error TS1039: Initializers are not allowed in ambient contexts.