Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:62761 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 17670 invoked from network); 3 Sep 2012 17:51:31 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 3 Sep 2012 17:51:31 -0000 Authentication-Results: pb1.pair.com header.from=ajf@ajf.me; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=ajf@ajf.me; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain ajf.me designates 64.22.89.133 as permitted sender) X-PHP-List-Original-Sender: ajf@ajf.me X-Host-Fingerprint: 64.22.89.133 oxmail.registrar-servers.com Received: from [64.22.89.133] ([64.22.89.133:55947] helo=oxmail.registrar-servers.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 36/A3-20751-22EE4405 for ; Mon, 03 Sep 2012 13:51:31 -0400 Received: from [192.168.0.200] (5ad3285b.bb.sky.com [90.211.40.91]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by oxmail.registrar-servers.com (Postfix) with ESMTPSA id 6A2FC7580CD; Mon, 3 Sep 2012 13:51:26 -0400 (EDT) Message-ID: <5044EDF5.7040407@ajf.me> Date: Mon, 03 Sep 2012 18:50:45 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:14.0) Gecko/20120714 Thunderbird/14.0 MIME-Version: 1.0 To: Sherif Ramadan CC: Derick Rethans , Laruence , Jared Williams , internals@lists.php.net References: <20120902230741.TSGJ23973.aamtaout03-winn.ispmail.ntl.com@p2> <5044EAB4.40003@ajf.me> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] Foreach list behaviour From: ajf@ajf.me (Andrew Faulds) On 03/09/12 18:46, Sherif Ramadan wrote: > > It should absolute not cast anything. list($a, $b) = $c; is the > equivalent of saying $a = $c[0]; $b = $c[1]; In this case $c just > happens to be a scalar value and as such you can not derive anything > from the scalar value in that context. It is implicitly null. Ah, I guess I'm confusing GML and PHP array semantics, somehow... my bad. -- Andrew Faulds http://ajf.me/