Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:3950 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 21438 invoked from network); 14 Aug 2003 19:14:05 -0000 Received: from unknown (HELO mail.3gstech.com) (216.239.132.110) by pb1.pair.com with SMTP; 14 Aug 2003 19:14:05 -0000 Received: from 3gstech.com (ip-209-172-92-41.us01.qualys.com [209.172.92.41]) by mail.3gstech.com (Postfix) with ESMTP id 8E1B49E7B11; Thu, 14 Aug 2003 12:14:03 -0700 (PDT) Message-ID: <3F3BDEEE.4000106@3gstech.com> Date: Thu, 14 Aug 2003 12:11:42 -0700 User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.3) Gecko/20030312 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Timm Friebe Cc: internals@lists.php.net References: <1060813541.901.336.camel@ali> <20030814131812.18761.qmail@pb1.pair.com> <1060886610.50229.9.camel@localhost> In-Reply-To: <1060886610.50229.9.camel@localhost> Content-Type: multipart/alternative; boundary="------------090807010204010800070003" Subject: Re: [PHP-DEV] Re: variable_exists() patch From: waboring@3gstech.com (walt boring) --------------090807010204010800070003 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Timm Friebe wrote: >On Thu, 2003-08-14 at 13:18, nicos@php.net wrote: >[...] > > >>Hmm, I thought a variable is set even if its value is NULL? >> >> > >Unfortunately it is not: > >thekid@friebes:~ > php -r '$a= NULL; var_dump(isset($a));' >bool(false) > >- Timm > > > > exactly why isset() is either 1) a bad name for the function or 2) 'broken' Since the isset() documentation explicitly warns that it will return false if the value is set and is NULL, one could say that option 2 is invalid. So, in my opinion isset() is really a bad choice for a name of that functionality, and why something like variable_exists() is needed. Maybe it could just be called exists() ? I'm sure changing the functionality of isset() isn't really an option at this point for all of the existing apps that use it. Walt --------------090807010204010800070003--