// @strict: true // Repro from #17148 class Foo { myFunc(arg: T) {} } class Bar { myFunc(arg: T) {} } const myVar: Foo = new Bar();