Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:35510 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 25615 invoked by uid 1010); 15 Feb 2008 09:30:37 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 25600 invoked from network); 15 Feb 2008 09:30:37 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 15 Feb 2008 09:30:37 -0000 Authentication-Results: pb1.pair.com header.from=jani.taskinen@sci.fi; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=jani.taskinen@sci.fi; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain sci.fi from 63.208.196.178 cause and error) X-PHP-List-Original-Sender: jani.taskinen@sci.fi X-Host-Fingerprint: 63.208.196.178 mho-01-bos.mailhop.org Received: from [63.208.196.178] ([63.208.196.178:59064] helo=mho-01-bos.mailhop.org) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id EE/03-26828-0BB55B74 for ; Fri, 15 Feb 2008 04:30:34 -0500 Received: from [81.22.163.71] (helo=[10.6.109.198]) by mho-01-bos.mailhop.org with esmtpsa (SSLv3:RC4-MD5:128) (Exim 4.68) (envelope-from ) id 1JPwte-000NWO-BZ; Fri, 15 Feb 2008 09:30:18 +0000 X-Mail-Handler: MailHop Outbound by DynDNS X-Originating-IP: 81.22.163.71 X-Report-Abuse-To: abuse@dyndns.com (see http://www.mailhop.org/outbound/abuse.html for abuse reporting information) X-MHO-User: U2FsdGVkX1/Ef8TWGpvtYelpM/aMti035blHtUiGmTE= Reply-To: jani.taskinen@iki.fi To: Dmitry Stogov Cc: Marcus Boerger , PHP Internals List , Andi Gutmans In-Reply-To: <47B54F0C.2090700@zend.com> References: <971575499.20080209153315@marcus-boerger.de> <47B54F0C.2090700@zend.com> Content-Type: text/plain Date: Fri, 15 Feb 2008 11:30:15 +0200 Message-ID: <1203067815.10500.5.camel@localhost.localdomain> Mime-Version: 1.0 X-Mailer: Evolution 2.8.3 (2.8.3-2.fc6) Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] [RFC] Conditional INI support From: jani.taskinen@sci.fi (Jani Taskinen) On Fri, 2008-02-15 at 11:36 +0300, Dmitry Stogov wrote: > a) I think we don't need (1) ternary support at all, as (2) > if-elif=else-endif may do the same. That was already dropped. :) > b) I think usage of square brackets is not a good idea, because they are > commonly used to divide ini files into sections. Why not to use C > syntax? (#if...) I'd prefer that syntax too, it would be much clearer than mixing the sections with this. It's also backwards compatible, lines prefixed with # are simply ignored. > c) We can use just "value" insted of ${value} in conditions. Yup. ${foobar} is actually not any "variable" per se, but just a reference to existing ini entry in the file. And I don't think that needs to change. > d) I would prefer not to use '.' in the variables name. It will allow to > distribute conditional ini files, and use them with old PHP versions > after manual preprocessing (using cpp). . is acceptable since it's acceptable in ini directive names too. And works just fine in pre 5.3 versions too. > e) We don't need to define special names, we can use internal PHP constants. Yup, I mentioned this a couple of times already. :) --Jani -- Patches/Donations: http://pecl.php.net/~jani/