TypeScript/tests/cases/conformance/functions/strictBindCallApply2.ts
Anders Hejlsberg df3b5bbdab
Fix ThisParameterType<T> type (#36013)
* Simplify ThisParameterType<T> type

* Add tests
2020-01-06 08:55:34 -10:00

12 lines
236 B
TypeScript

// @strictFunctionTypes: false
// @strictBindCallApply: true
// Repro from #32964
interface Foo { blub: string };
function fn(this: Foo) {}
type Test = ThisParameterType<typeof fn>;
const fb = fn.bind({ blub: "blub" });