mirror of
https://github.com/danog/psalm.git
synced 2024-11-26 20:34:47 +01:00
Add test for #1422
This commit is contained in:
parent
f9b1a63146
commit
becef300b1
@ -749,6 +749,18 @@ class MethodSignatureTest extends TestCase
|
|||||||
}',
|
}',
|
||||||
'error_message' => 'InvalidReturnStatement',
|
'error_message' => 'InvalidReturnStatement',
|
||||||
],
|
],
|
||||||
|
'preventInterfaceOverload' => [
|
||||||
|
'<?php
|
||||||
|
interface I {
|
||||||
|
public function f(float ...$rest): void;
|
||||||
|
}
|
||||||
|
|
||||||
|
class C implements I {
|
||||||
|
/** @param array<int,float> $f */
|
||||||
|
public function f($f): void {}
|
||||||
|
}',
|
||||||
|
'error_message' => 'MethodSignatureMismatch',
|
||||||
|
],
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user