mirror of
https://github.com/php/php-src.git
synced 2025-01-05 18:33:56 +08:00
afec3a9208
Fixes bug #76451, and more importantly lays necessary groundwork for covariant/contravariant types. Bug #76451 is just an edge case, but once covariance is introduced this will become a common problem instead.
9 lines
119 B
PHP
9 lines
119 B
PHP
<?php
|
|
class A {
|
|
public function test(Foo $foo) {}
|
|
}
|
|
class B extends A {
|
|
public function test(Bar $foo) {}
|
|
}
|
|
?>
|