#34521 [Opn->Bgs]: Extending multiple interfaces with the same method fails
| From: | lachlan at sitepoint dot com | Date: | Fri, 16 Sep 2005 02:42:15 +0000 |
| Subject: | #34521 [Opn->Bgs]: Extending multiple interfaces with the same method fails | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-85130@lists.php.net to get a copy of this message | ||
ID: 34521
User updated by: lachlan at sitepoint dot com
Reported By: lachlan at sitepoint dot com
-Status: Open
+Status: Bogus
Bug Type: Class/Object related
Operating System: Win32
PHP Version: 5.0.5
New Comment:
Due to the lack of overloading in the engine a fatal error is probably
the desired behaviour for this scenario.
Previous Comments:
------------------------------------------------------------------------
[2005-09-16 04:23:52] lachlan at sitepoint dot com
Description:
------------
When multiple interfaces with common method names are extended by an
interface an error is raised.
Reproduce code:
---------------
interface a { function foo($bar); }
interface b { function foo($bar); }
interface ab extends a,b {}
Result:
Fatal error: Can't inherit abstract function b::foo() (previously
declared abstract in a)
Expected result:
----------------
The code should parse cleanly
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=34521&edit=1