Closed
Description
TypeScript Version: 2.6.1
Code
interface A {
x: number;
}
interface B {
y: number;
}
function onEvent(callback: (param: A) => void): void {
}
onEvent((param: A & B) => {
console.log('Hello');
});
Expected behavior:
- passing the arrow function to onEvent should be flagged as an error
Actual behavior:
- it is not flagged.