Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:59531 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 58092 invoked from network); 9 Apr 2012 19:16:35 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 9 Apr 2012 19:16:35 -0000 Authentication-Results: pb1.pair.com header.from=keisial@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=keisial@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 74.125.82.170 as permitted sender) X-PHP-List-Original-Sender: keisial@gmail.com X-Host-Fingerprint: 74.125.82.170 mail-we0-f170.google.com Received: from [74.125.82.170] ([74.125.82.170:37807] helo=mail-we0-f170.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 49/15-34074-295338F4 for ; Mon, 09 Apr 2012 15:16:34 -0400 Received: by werh12 with SMTP id h12so3265466wer.29 for ; Mon, 09 Apr 2012 12:16:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=99MniF6HeVjjj9zMygNi/L+AFlXSkYN1HvdAgr5eFdY=; b=Gay5mzIHeWkQEb/dJupITttmUNpWqgA9H91SUCGjXbm+MTJBA//UPunOBmxrF/e2e1 Cbrhi7rfZl66Vir9SqbPzr/M+/8WwIMbopH5PnfWq2SRUPPwXRLUocCkJ1ZK/wPJJCSq jNJfyNl0dVY+Bx12jQLdNDhiBkh4VAbBuXFnlE8bGX5nsSc9iwIjGrkw3nZkDKE0ra7L e8zaNsyNCA1SI83GnsLMRkmsw65/UcY26FLoRyimZUO8K3NXt1JXHOVIpx2hZqLu71R1 jHfrAcxx8zXEAPxkQdmZ82lJu8IkgpW84dUTM9HojDOz35hZEKhyKBwzWEFo3Z3HAWGG Q1yg== Received: by 10.216.134.27 with SMTP id r27mr4705093wei.107.1333998991019; Mon, 09 Apr 2012 12:16:31 -0700 (PDT) Received: from [192.168.1.26] (123.Red-193-153-87.dynamicIP.rima-tde.net. [193.153.87.123]) by mx.google.com with ESMTPS id fl2sm47523714wib.2.2012.04.09.12.16.29 (version=SSLv3 cipher=OTHER); Mon, 09 Apr 2012 12:16:30 -0700 (PDT) Message-ID: <4F8336CA.6030800@gmail.com> Date: Mon, 09 Apr 2012 21:21:46 +0200 User-Agent: Thunderbird MIME-Version: 1.0 To: Chris Stockton CC: PHP Developers Mailing List References: <-5877502932356715576@unknownmsgid> <-3647345967307864634@unknownmsgid> <4F831FAE.2030208@ralphschindler.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] RFC: source files without opening tag From: keisial@gmail.com (=?ISO-8859-1?Q?=C1ngel_Gonz=E1lez?=) On 09/04/12 20:23, Chris Stockton wrote: > Hello, > Although I am not very interested in this feature, if it is > implemented I like the idea of flags instead of introducing new > keywords. Maintaining backwards compatibility would be great > considering the benefit to the feature to be completely honest (and in > disagreement to many people, but I do understand the reasoning for > everyone's interest in it) is extremely minor in my eyes. > > In addition I would suggest maybe using PHP_INCLUDE_* as a place for > these constants to live. > > -Chris That would still be a parse error. Either include "file.php", 5; or include ("file.php", 42); Fails with a parse error about unexpected ',' On the other hand, a new keyword can be written in a backwards compatible way by making it look like a function call in a non-taken branch: *if ( version_compare(PHP_VERSION*, '5.5', '<') ) include_once $file; else require_code($file, array( 'once'=>true, 'warn' => 'ignore' ) );