Re: [RFC] Property Accessors v1.2 : isset / unset "failable"
| From: | Pierre Joye | Date: | Sun, 28 Oct 2012 09:02:23 +0000 |
| Subject: | Re: [RFC] Property Accessors v1.2 : isset / unset "failable" | ||
| References: | 1 2 3 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-63688@lists.php.net to get a copy of this message | ||
hi Clint,
On Sat, Oct 27, 2012 at 7:39 PM, Clint Priest <cpriest@zerocue.com> wrote:
> That's basically what #2 is getting at, my only question is, emit a warning
> or notice or not?
>
> Technically returning false on an invalid isset() call could be misleading
> without emitting some kind of notice or warning about it.
isset is used for this exact purpose, avoid noisy scripts while
testing the existence (instance, init'ed, etc.) of a variable or
property. Raising a notice here sounds wrong, no matter in which
context.
Cheers,
--
Pierre
@pierrejoye | http://blog.thepimp.net | http://www.libgd.org