note 54639 deleted from language.oop5.decon by cmb

From: Date: Sun, 08 Sep 2019 10:23:40 +0000
Subject: note 54639 deleted from language.oop5.decon by cmb
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-212135@lists.php.net to get a copy of this message
Note Submitter: dominics at gmail dot com ---- If you're using E_STRICT error reporting, PHP will tell you if you define both __construct() and an old-style constructor (a function with the same name as the class) together in a class. Note that this occurs even if the old constructor function is abstract or final (for instance, if you were intending to only use it in a sub-class). Be wary of this if you're trying to implement the 'command' design pattern. The solution? Either turn E_STRICT off (and possibly forgo some other important notices), rename your function (and possibly make things a little more complicated), or look at using an interface.

« previous php.notes (#212135) next »