Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:22799 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 69933 invoked by uid 1010); 16 Apr 2006 22:54:25 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 69918 invoked from network); 16 Apr 2006 22:54:25 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 16 Apr 2006 22:54:25 -0000 X-Host-Fingerprint: 87.123.64.63 i577B403F.versanet.de Received: from ([87.123.64.63:9961] helo=localhost.localdomain) by pb1.pair.com (ecelerity 2.0 beta r(6323M)) with SMTP id 78/C2-19715-02BC2444 for ; Sun, 16 Apr 2006 18:54:24 -0400 To: internals@lists.php.net,Derick Rethans Message-ID: <4442CB1E.7050508@php.net> Date: Mon, 17 Apr 2006 00:54:22 +0200 User-Agent: Thunderbird 1.5 (Windows/20051201) MIME-Version: 1.0 CC: itrebal@gmail.com References: <2e24b1e00604150752g69acab4er1058771d9e60a352@mail.gmail.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Posted-By: 87.123.64.63 Subject: Re: [PHP-DEV] Inconsistency of empty() and isset() ? From: lsmith@php.net (Lukas Smith) Derick Rethans wrote: > On Sat, 15 Apr 2006 itrebal@gmail.com wrote: > >> The following is a direct excerpt from the PHP manual on empty, and isset: >> bool *empty* ( mixed var ) >> bool *isset* ( mixed var [, mixed var [, ...]] ) >> Is there a reason empty does not allow multiple variables at a time, as >> isset? Was there thought behind it, or is it just an inconsistency? > > There is a thought about it, and that is that we could not decide > whether it should be an AND or an OR test between the different > parameters. well it seems to be AND for isset() .. which is probably its closest "sibiling" .. so the obvious call when going for consistency would be to AND in empty() as well .. regards, Lukas