Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:53758 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 63471 invoked from network); 6 Jul 2011 13:06:28 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 6 Jul 2011 13:06:28 -0000 Authentication-Results: pb1.pair.com header.from=hannes.magnusson@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=hannes.magnusson@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.213.170 as permitted sender) X-PHP-List-Original-Sender: hannes.magnusson@gmail.com X-Host-Fingerprint: 209.85.213.170 mail-yx0-f170.google.com Received: from [209.85.213.170] ([209.85.213.170:48724] helo=mail-yx0-f170.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 1C/32-48910-3DD541E4 for ; Wed, 06 Jul 2011 09:06:27 -0400 Received: by yxk8 with SMTP id 8so2675513yxk.29 for ; Wed, 06 Jul 2011 06:06:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; bh=rj1BE5vxbUFEzu7u1HcuLeHE7Gw4PRn7gglgX5wRTg8=; b=j2wGSxSRWoH9by2ljpCxLU0VZFYem7+q6gywg36lSMmKwe1qyfTgNggPOjv5ZsF1a7 Jmpjb2IRkvL8gEU/eK76EVUqHXgULoXBq0rUF7EpC4Ed/aU34X1Bxgx139lWMPtX/XWJ IdDfFfck5ErcUwCd9VFLJ525TP1qt7bLsn+3k= MIME-Version: 1.0 Received: by 10.147.86.18 with SMTP id o18mr7064135yal.17.1309957584417; Wed, 06 Jul 2011 06:06:24 -0700 (PDT) Received: by 10.146.210.3 with HTTP; Wed, 6 Jul 2011 06:06:24 -0700 (PDT) In-Reply-To: References: Date: Wed, 6 Jul 2011 15:06:24 +0200 Message-ID: To: Xinchen Hui Cc: internals@lists.php.net, Pierre Joye , =?UTF-8?Q?Johannes_Schl=C3=BCter?= Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [PHP-DEV] [RFC] foreach_variable supporting T_LIST token From: hannes.magnusson@gmail.com (Hannes Magnusson) 2011/7/6 Xinchen Hui : > Hi: > > =C2=A0 T_LIST is not allowed to used with foreach before. > > =C2=A0 and then there comes a freature request: =C2=A0#10203 =C2=A0allow > foreach($array as list($a,$b) Ironically enough you managed to miss the last closing ), enforcing the point of this not being a natural syntax. Furthermore, without reading the RFC, is this the same as foreach($array as $a =3D> $b) {} or foreach($array as $e) { list($a, $b) =3D $e; } or.. ? that really doesn't look like something PHP should support imo. -Hannes