Re: [VOTE] get_class() disallow null parameter

From: Date: Sun, 25 Sep 2016 12:20:02 +0000
Subject: Re: [VOTE] get_class() disallow null parameter
References: 1 2  Groups: php.internals 
Request: Send a blank email to internals+get-96133@lists.php.net to get a copy of this message
On 25 September 2016 at 06:29, Pierre Joye <pierre.php@gmail.com> wrote: > I am pretty sure it is by design (for what I can remember) I do not believe that is correct. The commit message* says: "Restore PHP-5.2 behaviour when passing null inside object scope to get_class()" The commit does not restore the previous behaviour.** I'm pretty certain it was just a mistake. As Leigh noted, the behaviour is not clearly documented. In fact the manual also says: "If get_class() is called with anything other than an object, an E_WARNING level error is raised.". I'm pretty sure that null is not an object, so this RFC actually moves the behaviour closer to what the manual says. > I recommend the (future) RMs to veto this change. It is the role for Release Managers to prevent accidental changes happening, and to prevent changes being applied to releases when they haven't gone through the RFC process. Is is not the role of a Release Manager to prevent clear RFCs that have been through the RFC process from being applied. cheers Dan Ack * https://github.com/php/php-src/commit/dc74c5136e227bdc2ba1f2ce6f99170a7cf18cc8#diff-3ea93da7d1026a9f53948a5d14b1f7bd ** https://3v4l.org/f3G4N

« previous php.internals (#96133) next »