Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:35040 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 93787 invoked by uid 1010); 30 Jan 2008 19:46:06 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 93772 invoked from network); 30 Jan 2008 19:46:06 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 30 Jan 2008 19:46:06 -0000 Authentication-Results: pb1.pair.com smtp.mail=rasmus@lerdorf.com; spf=permerror; sender-id=unknown Authentication-Results: pb1.pair.com header.from=rasmus@lerdorf.com; sender-id=unknown Received-SPF: error (pb1.pair.com: domain lerdorf.com from 207.126.228.150 cause and error) X-PHP-List-Original-Sender: rasmus@lerdorf.com X-Host-Fingerprint: 207.126.228.150 rsmtp2.corp.yahoo.com FreeBSD 4.7-5.2 (or MacOS X 10.2-10.3) (2) Received: from [207.126.228.150] ([207.126.228.150:27924] helo=rsmtp2.corp.yahoo.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id D3/B3-14302-AF3D0A74 for ; Wed, 30 Jan 2008 14:46:05 -0500 Received: from [216.145.54.7] (socks2.corp.yahoo.com [216.145.54.7]) by rsmtp2.corp.yahoo.com (8.13.8/8.13.8/y.rout) with ESMTP id m0UJjt0P035470; Wed, 30 Jan 2008 11:45:55 -0800 (PST) Message-ID: <47A0D72E.2010503@lerdorf.com> Date: Wed, 30 Jan 2008 11:59:42 -0800 User-Agent: Thunderbird 1.5.0.7 (X11/20060911) MIME-Version: 1.0 To: Greg Beaver CC: php-dev References: <479114FD.6010005@zend.com> <47A07E86.4010008@zend.com> <47A08314.60507@daylessday.org> <47A08FC5.8020208@zend.com> <47A0D237.4020306@php.net> In-Reply-To: <47A0D237.4020306@php.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] nowdocs again From: rasmus@lerdorf.com (Rasmus Lerdorf) Greg Beaver wrote: > Dmitry Stogov wrote: >> The feature is very useful, however, I agree, the syntax would be >> better. :) >> The current syntax: >> >> $var = <<<'TEXT' >> text >> TEXT; > > I would like to see nowdocs. The closest equivalent in another syntax I > can think of is xml's CDATA. Perhaps we can borrow something similar to > that syntax > > $var = << string here > ]CDATA; No, please, let's not further promote CDATA abuse. Everyone seems to think that CDATA is some sort of binary-clean way to toss any junk they want into an XML file which isn't even close to being true. I don't think the 'FOO' syntax is very obvious either, but I can't think of a better one and if there isn't a commonly known syntax we can steal from another language, then making up our own, no matter what it is, is going to be non-obvious to a lot of people. -Rasmus