61 lines
2.3 KiB
Text
61 lines
2.3 KiB
Text
=== tests/cases/conformance/statements/VariableStatements/recursiveInitializer.ts ===
|
|
// number unless otherwise specified
|
|
var n1 = n1++;
|
|
>n1 : Symbol(n1, Decl(recursiveInitializer.ts, 1, 3))
|
|
>n1 : Symbol(n1, Decl(recursiveInitializer.ts, 1, 3))
|
|
|
|
var n2: number = n2 + n2;
|
|
>n2 : Symbol(n2, Decl(recursiveInitializer.ts, 2, 3))
|
|
>n2 : Symbol(n2, Decl(recursiveInitializer.ts, 2, 3))
|
|
>n2 : Symbol(n2, Decl(recursiveInitializer.ts, 2, 3))
|
|
|
|
var n3 /* any */ = n3 + n3;
|
|
>n3 : Symbol(n3, Decl(recursiveInitializer.ts, 3, 3))
|
|
>n3 : Symbol(n3, Decl(recursiveInitializer.ts, 3, 3))
|
|
>n3 : Symbol(n3, Decl(recursiveInitializer.ts, 3, 3))
|
|
|
|
// string unless otherwise specified
|
|
var s1 = s1 + '';
|
|
>s1 : Symbol(s1, Decl(recursiveInitializer.ts, 6, 3))
|
|
>s1 : Symbol(s1, Decl(recursiveInitializer.ts, 6, 3))
|
|
|
|
var s2 /* any */ = s2 + s2;
|
|
>s2 : Symbol(s2, Decl(recursiveInitializer.ts, 7, 3))
|
|
>s2 : Symbol(s2, Decl(recursiveInitializer.ts, 7, 3))
|
|
>s2 : Symbol(s2, Decl(recursiveInitializer.ts, 7, 3))
|
|
|
|
var s3 : string = s3 + s3;
|
|
>s3 : Symbol(s3, Decl(recursiveInitializer.ts, 8, 3))
|
|
>s3 : Symbol(s3, Decl(recursiveInitializer.ts, 8, 3))
|
|
>s3 : Symbol(s3, Decl(recursiveInitializer.ts, 8, 3))
|
|
|
|
var s4 = '' + s4;
|
|
>s4 : Symbol(s4, Decl(recursiveInitializer.ts, 9, 3))
|
|
>s4 : Symbol(s4, Decl(recursiveInitializer.ts, 9, 3))
|
|
|
|
// boolean unless otherwise specified
|
|
var b1 = !b1;
|
|
>b1 : Symbol(b1, Decl(recursiveInitializer.ts, 12, 3))
|
|
>b1 : Symbol(b1, Decl(recursiveInitializer.ts, 12, 3))
|
|
|
|
var b2 = !!b2;
|
|
>b2 : Symbol(b2, Decl(recursiveInitializer.ts, 13, 3))
|
|
>b2 : Symbol(b2, Decl(recursiveInitializer.ts, 13, 3))
|
|
|
|
var b3 = !b3 || b3; // expected boolean here. actually 'any'
|
|
>b3 : Symbol(b3, Decl(recursiveInitializer.ts, 14, 3))
|
|
>b3 : Symbol(b3, Decl(recursiveInitializer.ts, 14, 3))
|
|
>b3 : Symbol(b3, Decl(recursiveInitializer.ts, 14, 3))
|
|
|
|
var b4 = (!b4) && b4; // expected boolean here. actually 'any'
|
|
>b4 : Symbol(b4, Decl(recursiveInitializer.ts, 15, 3))
|
|
>b4 : Symbol(b4, Decl(recursiveInitializer.ts, 15, 3))
|
|
>b4 : Symbol(b4, Decl(recursiveInitializer.ts, 15, 3))
|
|
|
|
// (x:string) => any
|
|
var f = (x: string) => f(x);
|
|
>f : Symbol(f, Decl(recursiveInitializer.ts, 18, 3))
|
|
>x : Symbol(x, Decl(recursiveInitializer.ts, 18, 9))
|
|
>f : Symbol(f, Decl(recursiveInitializer.ts, 18, 3))
|
|
>x : Symbol(x, Decl(recursiveInitializer.ts, 18, 9))
|
|
|