29 lines
610 B
Text
29 lines
610 B
Text
=== tests/cases/compiler/stringPropCodeGen.ts ===
|
|
var a = {
|
|
>a : { "foo": () => void; "bar": number; }
|
|
>{ "foo" : function() { }, "bar" : 5} : { "foo": () => void; "bar": number; }
|
|
|
|
"foo" : function() { },
|
|
>function() { } : () => void
|
|
|
|
"bar" : 5
|
|
>5 : number
|
|
|
|
};
|
|
|
|
|
|
|
|
a.foo();
|
|
>a.foo() : void
|
|
>a.foo : () => void
|
|
>a : { "foo": () => void; "bar": number; }
|
|
>foo : () => void
|
|
|
|
a.bar.toString();
|
|
>a.bar.toString() : string
|
|
>a.bar.toString : (radix?: number) => string
|
|
>a.bar : number
|
|
>a : { "foo": () => void; "bar": number; }
|
|
>bar : number
|
|
>toString : (radix?: number) => string
|
|
|