Re: variable_exists() patch
| From: | Lars Torben Wilson | Date: | Sat, 16 Aug 2003 21:42:17 +0000 |
| Subject: | Re: variable_exists() patch | ||
| References: | 1 2 3 4 5 6 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-4026@lists.php.net to get a copy of this message | ||
On Sat, 2003-08-16 at 14:41, Zeev Suraski wrote:
> At 16:53 16/08/2003, Robert Cummings wrote:
> >So it seems to me that a null value does not define the non-existence of
> >a value, but is itself actually a value. And this as far as I am
> >concerned is quite valid.
>
> Ok, but it still doesn't change the fact that null is not a value :) The
> fact we couldn't make the implementation perfect doesn't change that in any
> way.
> I mentioned ways to implement the desired behavior, others also mentioned
> other ways - but there's no way I'd support adding functionality that will
> encourage inconsistency in the language.
>
> Zeev
But the change would make it more consistent, by recognizing that a
variable with a NULL value is still defined. Pretending that $foo =
null and unset($foo) are the same thing is quite inconsistent and
confusing for many, when there are ways (i.e. get_defined_vars()) to
prove that they are not the same.
--
Torben Wilson <torben@php.net> +1.604.709.0506
http://www.thebuttlesschaps.com http://www.inflatableeye.com
http://www.hybrid17.com http://www.themainonmain.com
-----==== Boycott Starbucks! http://www.haidabuckscafe.com ====-----