php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #37345 Multiple inheritance in PHP6
Submitted: 2006-05-07 05:38 UTC Modified: 2006-05-07 09:54 UTC
Votes:29
Avg. Score:4.7 ± 0.7
Reproduced:24 of 25 (96.0%)
Same Version:19 (79.2%)
Same OS:20 (83.3%)
From: gustavo@php.net Assigned:
Status: Wont fix Package: Feature/Change Request
PHP Version: * OS: *
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: gustavo@php.net
New email:
PHP Version: OS:

 

 [2006-05-07 05:38 UTC] gustavo@php.net
Description:
------------
Hi.

I know this is not the first time someone requests multiple inheritance in PHP, but I really think you should consider it as interfaces are not always acceptable.

For instance, with the current single-inheritance model, if I'm working with the ActiveRecord pattern and want to add some adapter-independant methods, I'd have to copy and paste the _same_ code for each driver/adapter. This is not handy at all.

I'd be nice to count with this feature in the next major release.

Cheers!

Expected result:
----------------
Multiple-inheritance support

Actual result:
--------------
Single-inheritance support (only)

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2006-05-07 09:54 UTC] helly@php.net
.
 [2013-06-18 19:53 UTC] parad0x dot ua at gmail dot com
I asked for multiple inheritance and all I got was lousy Traits (PHP >= 5.4):
http://php.net/manual/en/language.oop5.traits.php
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Dec 27 01:01:28 2024 UTC