=== tests/cases/compiler/contextualTyping4.ts === class foo { public bar:{id:number;} = {id:5, name:"foo"}; } >foo : foo >bar : { id: number; } >id : number >{id:5, name:"foo"} : { id: number; name: string; } >id : number >5 : number >name : string >"foo" : string