TypeScript/tests/baselines/reference/modFunctionCrash.types
2015-04-15 16:44:20 -07:00

19 lines
419 B
Plaintext

=== tests/cases/compiler/modFunctionCrash.ts ===
declare module Q {
>Q : typeof Q
function f(fn:()=>void); // typechecking the function type shouldnot crash the compiler
>f : (fn: () => void) => any
>fn : () => void
}
Q.f(function() {this;});
>Q.f(function() {this;}) : any
>Q.f : (fn: () => void) => any
>Q : typeof Q
>f : (fn: () => void) => any
>function() {this;} : () => void
>this : any