TypeScript/tests/baselines/reference/funduleUsedAcrossFileBoundary.types

40 lines
831 B
Plaintext
Raw Normal View History

2014-08-15 23:33:16 +02:00
=== tests/cases/compiler/funduleUsedAcrossFileBoundary_file1.ts ===
declare function Q<T>(value: T): string;
>Q : typeof Q
>T : T
>value : T
>T : T
2014-08-15 23:33:16 +02:00
declare module Q {
>Q : typeof Q
2014-08-15 23:33:16 +02:00
interface Promise<T> {
>Promise : Promise<T>
>T : T
2014-08-15 23:33:16 +02:00
foo: string;
>foo : string
2014-08-15 23:33:16 +02:00
}
export function defer<T>(): string;
>defer : <T>() => string
>T : T
2014-08-15 23:33:16 +02:00
}
=== tests/cases/compiler/funduleUsedAcrossFileBoundary_file2.ts ===
function promiseWithCancellation<T>(promise: Q.Promise<T>) {
>promiseWithCancellation : <T>(promise: Q.Promise<T>) => void
>T : T
>promise : Q.Promise<T>
>Q : any
>Promise : Q.Promise<T>
>T : T
2014-08-15 23:33:16 +02:00
var deferred = Q.defer<T>(); // used to be an error
>deferred : string
2014-08-15 23:33:16 +02:00
>Q.defer<T>() : string
>Q.defer : <T>() => string
>Q : typeof Q
>defer : <T>() => string
>T : T
2014-08-15 23:33:16 +02:00
}