Skip to content

Commit 1c2f3d2

Browse files
committed
Add regression test
1 parent deb87bb commit 1c2f3d2

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
// @strict: true
2+
3+
// Repro from #22823
4+
5+
interface Props {
6+
foo?: boolean;
7+
}
8+
9+
function foo<P extends Props>(props: Readonly<P>) {
10+
let { foo = false } = props;
11+
if (foo === true) { }
12+
}

0 commit comments

Comments
 (0)