Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:52575 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 79573 invoked from network); 31 May 2011 20:28:28 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 31 May 2011 20:28:28 -0000 Authentication-Results: pb1.pair.com header.from=smalyshev@sugarcrm.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=smalyshev@sugarcrm.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain sugarcrm.com designates 207.97.245.133 as permitted sender) X-PHP-List-Original-Sender: smalyshev@sugarcrm.com X-Host-Fingerprint: 207.97.245.133 smtp133.iad.emailsrvr.com Linux 2.6 Received: from [207.97.245.133] ([207.97.245.133:59513] helo=smtp133.iad.emailsrvr.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 77/1A-25701-B6F45ED4 for ; Tue, 31 May 2011 16:28:28 -0400 Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp53.relay.iad1a.emailsrvr.com (SMTP Server) with ESMTP id D2988583A8; Tue, 31 May 2011 16:28:24 -0400 (EDT) X-Virus-Scanned: OK Received: by smtp53.relay.iad1a.emailsrvr.com (Authenticated sender: smalyshev-AT-sugarcrm.com) with ESMTPSA id 4103258235; Tue, 31 May 2011 16:28:24 -0400 (EDT) Message-ID: <4DE54F67.60003@sugarcrm.com> Date: Tue, 31 May 2011 13:28:23 -0700 Organization: SugarCRM User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.17) Gecko/20110414 Thunderbird/3.1.10 MIME-Version: 1.0 To: Sean Coates CC: Brian Moon , PHP internals References: <4DE5368A.6050603@moonspot.net> <2BFFEAC1-395E-4101-9452-002E63DCFD91@seancoates.com> In-Reply-To: <2BFFEAC1-395E-4101-9452-002E63DCFD91@seancoates.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] RFC: Short syntax for Arrays (redux) From: smalyshev@sugarcrm.com (Stas Malyshev) Hi! > At risk of turning this into a longer-than-necessary discussion, I > believe a new RFC is required at this point. Making [ and ] work as > (T_ARRAY, '(') and (')'), respectively is no longer good enough, for > the main reason you've pointed out: JSON is becoming ubiquitous; > actual first-class JSON would be very valuable to me. It looks appealing, though if you think about security implications, I'm not sure it'd be actually as useful as one might think - i.e., you'd rarely want to eval() a JSON string, and absent that native JSON may not help you much. That aside, I think [] as array syntax is long overdue and would improve PHP readability and compatibility with other dynamic languages. -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227