Skip to content

Commit 22475e8

Browse files
committed
Add regression tests
1 parent 08cd0b3 commit 22475e8

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
// @strict: true
2+
3+
type Func1<T> = (x: T) => void;
4+
type Func2<T> = ((x: T) => void) | undefined;
5+
6+
declare let f1: Func1<string>;
7+
declare let f2: Func1<"a">;
8+
9+
declare function foo<T>(f1: Func1<T>, f2: Func1<T>): void;
10+
11+
foo(f1, f2);
12+
13+
declare let g1: Func2<string>;
14+
declare let g2: Func2<"a">;
15+
16+
declare function bar<T>(g1: Func2<T>, g2: Func2<T>): void;
17+
18+
bar(f1, f2);
19+
bar(g1, g2);

0 commit comments

Comments
 (0)