Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:52733 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 24284 invoked from network); 2 Jun 2011 04:20:11 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 2 Jun 2011 04:20:11 -0000 Authentication-Results: pb1.pair.com header.from=swhitemanlistens-software@cypressintegrated.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=swhitemanlistens-software@cypressintegrated.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain cypressintegrated.com designates 69.28.242.152 as permitted sender) X-PHP-List-Original-Sender: swhitemanlistens-software@cypressintegrated.com X-Host-Fingerprint: 69.28.242.152 rproxy1-a.cypressintegrated.com Windows 2000 SP4, XP SP1 Received: from [69.28.242.152] ([69.28.242.152:2442] helo=rproxy1-a.cypressintegrated.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 13/A2-32367-A7F07ED4 for ; Thu, 02 Jun 2011 00:20:11 -0400 Received: from bad.dop.co ([192.168.87.152]) by rproxy1-a.cypressintegrated.com (Brand New Heavy v1.0) with ASMTP id LKW99908; Thu, 02 Jun 2011 00:20:08 -0400 Date: Thu, 2 Jun 2011 00:19:39 -0400 Reply-To: Sanford Whiteman X-Priority: 3 (Normal) Message-ID: <68339132.20110602001939@cypressintegrated.com> To: John Crenshaw CC: PHP internals In-Reply-To: References: <4DE5368A.6050603@moonspot.net> <8BEEEE49-8DA3-4634-BF9C-120F7A15B613@roshambo.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] RFC: Short syntax for Arrays (redux) From: swhitemanlistens-software@cypressintegrated.com (Sanford Whiteman) > I don't think anyone cares about JSON for the sake of being perfect > JSON, I didn't intend to give that impression. Then you should stop saying "pure JSON" and "true JSON" constantly! > I'm only hoping for something that generally works on par with all > the other JSON parsers in the world. OK, that trashes your example, where values were set based on the result of a PHP function. There is no "par" for JSON parsers running methods _at creation time_, within the server (author) context. Setting vars to the return value of a function is something we take for granted in real languages, but it cannot happen within what a knowledgeable person would call "JSON." > Yes, JSON is a very specific encoding, but when a developer writes > something "jsony", what they mean is "an object/array with the > following structure/values", because that is what the encoding > really represents. Not Javascript developers. Maybe jQiddies think that {'$gt': strtotime('-1 day')} is "JSONy" more than it is "JS objecty"? This is like starting from "Wouldn't inline CSVs be great for creating arrays?" and drifting to "I mean, not like with that comma-escaping stuff, and, uh, newlines would be allowed in the middle of a record, and you'd have to allow create-time interpolation of function calls. You know, CSVy!" Only thing I might generously refer to as being "JSONy," while provably not being valid JSON, is a string that conforms in every way _except_ for using single quotes -- everywhere that doubles are required -- instead of using doubles. Anything else is someone's mangled "JankySON" or just not JSON. -- S.