1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84
|
=== tests/cases/compiler/recursiveTypeComparison2.ts ===
// Before fix this would cause compiler to hang (#1170)
declare module Bacon {
>Bacon : typeof Bacon
interface Event<T> {
}
interface Error<T> extends Event<T> {
}
interface Observable<T> {
zip<U, V>(other: EventStream<U>, f: (a: T, b: U) => V): EventStream<V>;
>zip : <U, V>(other: EventStream<U>, f: (a: T, b: U) => V) => EventStream<V>
>other : EventStream<U>
>f : (a: T, b: U) => V
>a : T
>b : U
slidingWindow(max: number, min?: number): Property<T[]>;
>slidingWindow : (max: number, min?: number) => Property<T[]>
>max : number
>min : number
log(): Observable<T>;
>log : () => Observable<T>
combine<U, V>(other: Observable<U>, f: (a: T, b: U) => V): Property<V>;
>combine : <U, V>(other: Observable<U>, f: (a: T, b: U) => V) => Property<V>
>other : Observable<U>
>f : (a: T, b: U) => V
>a : T
>b : U
withStateMachine<U, V>(initState: U, f: (state: U, event: Event<T>) => StateValue<U, V>): EventStream<V>;
>withStateMachine : <U, V>(initState: U, f: (state: U, event: Event<T>) => any) => EventStream<V>
>initState : U
>f : (state: U, event: Event<T>) => any
>state : U
>event : Event<T>
decode(mapping: Object): Property<any>;
>decode : (mapping: Object) => Property<any>
>mapping : Object
awaiting<U>(other: Observable<U>): Property<boolean>;
>awaiting : <U>(other: Observable<U>) => Property<boolean>
>other : Observable<U>
endOnError(f?: (value: T) => boolean): Observable<T>;
>endOnError : (f?: (value: T) => boolean) => Observable<T>
>f : (value: T) => boolean
>value : T
withHandler(f: (event: Event<T>) => any): Observable<T>;
>withHandler : (f: (event: Event<T>) => any) => Observable<T>
>f : (event: Event<T>) => any
>event : Event<T>
name(name: string): Observable<T>;
>name : (name: string) => Observable<T>
>name : string
withDescription(...args: any[]): Observable<T>;
>withDescription : (...args: any[]) => Observable<T>
>args : any[]
}
interface Property<T> extends Observable<T> {
}
interface EventStream<T> extends Observable<T> {
}
interface Bus<T> extends EventStream<T> {
}
var Bus: new <T>() => Bus<T>;
>Bus : new <T>() => Bus<T>
}
var stuck: Bacon.Bus<number> = new Bacon.Bus();
>stuck : Bacon.Bus<number>
>Bacon : any
>new Bacon.Bus() : Bacon.Bus<number>
>Bacon.Bus : new <T>() => Bacon.Bus<T>
>Bacon : typeof Bacon
>Bus : new <T>() => Bacon.Bus<T>
|