Closed
Description
function isA<A>(x: any, y: any): x is A | y is B {
return false;
}
var x: number | number[];
var y: string | string[];
if (isA<number>(x, y)) {
x, y;
}
else {
x, y;
}
It makes no sense, but parses correctly, doesn't error (despite the missing identifier), and shows up in quick info as boolean
.