TypeScript/tests/baselines/reference/symbolType11.types

41 lines
625 B
Plaintext
Raw Normal View History

2015-02-05 04:18:54 +01:00
=== tests/cases/conformance/es6/Symbols/symbolType11.ts ===
var s = Symbol.for("logical");
>s : symbol
2015-02-05 04:18:54 +01:00
>Symbol.for("logical") : symbol
>Symbol.for : (key: string) => symbol
>Symbol : SymbolConstructor
>for : (key: string) => symbol
2015-04-13 21:36:11 +02:00
>"logical" : string
2015-02-05 04:18:54 +01:00
s && s;
>s && s : symbol
>s : symbol
>s : symbol
2015-02-05 04:18:54 +01:00
s && [];
>s && [] : undefined[]
>s : symbol
2015-02-05 04:18:54 +01:00
>[] : undefined[]
0 && s;
>0 && s : symbol
2015-04-13 21:36:11 +02:00
>0 : number
>s : symbol
2015-02-05 04:18:54 +01:00
s || s;
>s || s : symbol
>s : symbol
>s : symbol
2015-02-05 04:18:54 +01:00
s || 1;
>s || 1 : number | symbol
>s : symbol
2015-04-13 21:36:11 +02:00
>1 : number
2015-02-05 04:18:54 +01:00
({}) || s;
>({}) || s : {}
2015-02-05 04:18:54 +01:00
>({}) : {}
>{} : {}
>s : symbol
2015-02-05 04:18:54 +01:00