19 lines
419 B
Text
19 lines
419 B
Text
|
=== 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
|
||
|
|