[wp-trac] [WordPress Trac] #34985: Remove PHP4 constructors in wp-includes/pomo/streams.php?

WordPress Trac noreply at wordpress.org
Wed Jan 20 09:49:59 UTC 2016


#34985: Remove PHP4 constructors in wp-includes/pomo/streams.php?
-------------------------------+------------------------------
 Reporter:  andg               |       Owner:
     Type:  defect (bug)       |      Status:  new
 Priority:  normal             |   Milestone:  Awaiting Review
Component:  I18N               |     Version:  4.4
 Severity:  normal             |  Resolution:
 Keywords:  needs-patch close  |     Focuses:
-------------------------------+------------------------------
Changes (by dd32):

 * keywords:  needs-patch => needs-patch close


Comment:

 I believe all of these constructors were dealt with in [32990].

 Instead of removing them (which we can't really do for backwards
 compatibility reasons) we chose to instead ensure that a `__construct()`
 appears before the `class_name()` constructor. This avoids the PHP7
 deprecated warnings, and even if PHP-future stops calling the
 `class_name()` methods they'll continue to work (as they now wrap the
 `__construct()` constructor).

 Do there still exist any classes which don't follow the new-then-old style
 syntax?

--
Ticket URL: <https://core.trac.wordpress.org/ticket/34985#comment:3>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list