This overload signature is not compatible with its implementation signature.
function printInc(a: number): void;
function printInc(a: string): void {
switch (typeof a) {
case 'string':
console.log(a + ' plus one');
break;
case 'number':
console.log(a + 1);
break;
}
}
function printInc(a: string | number): void {
switch (typeof a) {
case 'string':
console.log(a + ' plus one');
break;
case 'number':
console.log(a + 1);
break;
}
}