Re: Reclassify E_STRICT notices

From: Date: Tue, 03 Mar 2015 09:55:33 +0000
Subject: Re: Reclassify E_STRICT notices
References: 1 2 3 4  Groups: php.internals 
Request: Send a blank email to internals+get-84221@lists.php.net to get a copy of this message
On Mon, Mar 2, 2015 at 7:37 PM, Stanislav Malyshev <smalyshev@gmail.com> wrote: > Hi! > > > About the accessing static property non statically, I would have thrown > an > > E_ERROR : the property simply doesn't exist. Class properties should be > > accessed using the class, not an instance of it , IMO. > > Sometimes, there's no fixed class but there's an object of this class. > Doing something like $klass = get_class($foo); $klass::property is > possible, but $foo->property is easier. > Doing $obj::$property is possible as well, it does the same as get_class($obj)::$property. Nikita

« previous php.internals (#84221) next »