Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:16696 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 35511 invoked by uid 1010); 15 Jun 2005 16:49:34 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 35496 invoked from network); 15 Jun 2005 16:49:34 -0000 Received: from unknown (HELO lerdorf.com) (127.0.0.1) by localhost with SMTP; 15 Jun 2005 16:49:34 -0000 X-Host-Fingerprint: 204.11.219.139 lerdorf.com Linux 2.4/2.6 Received: from ([204.11.219.139:41225] helo=colo.lerdorf.com) by pb1.pair.com (ecelerity 1.2 r(5656M)) with SMTP id A7/7E-20931-ED450B24 for ; Wed, 15 Jun 2005 12:18:39 -0400 Received: from [192.168.2.106] (c-24-6-1-160.hsd1.ca.comcast.net [24.6.1.160]) (authenticated bits=0) by colo.lerdorf.com (8.13.4/8.13.4/Debian-3) with ESMTP id j5FGIYcT017122 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Wed, 15 Jun 2005 09:18:35 -0700 Message-ID: <42B054DA.5000403@lerdorf.com> Date: Wed, 15 Jun 2005 09:18:34 -0700 User-Agent: Mozilla Thunderbird 1.0.2 (Macintosh/20050317) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Stanislav Malyshev CC: Lukas Smith , internals@lists.php.net References: In-Reply-To: X-Enigmail-Version: 0.91.0.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] forward compatibility "public" in 4.4 From: rasmus@lerdorf.com (Rasmus Lerdorf) Stanislav Malyshev wrote: > LS>> > LS>>A while ago someone on IRC suggested that it might be a good idea to add > LS>>"public" to PHP 4.x for forward compatibility. I brought it up again on IRC > LS>>yesterday and several prominent members of the php core community said it > LS>>would be a good idea to add to the 4.4 branch. > > Why it would be a good idea? You couldn't run this code on 4.x{x<4} > anymore. And you still don't have php5 capabilities. So you get PHP > code which has all PHP 4 restrictions plus is not portable to arbitrary > PHP 4 version and requires only php 4.4 to run. How is it good? > > LS>>I think its a good idea to have, to make it somewhat possible to prepare for > LS>>the PHP5 E_STRICT world, while still developing PHP4 compatible code. I > LS>>could for example see this help increase the PHP5 adoption inside PEAR, > > Like, PEAR would drop support for PHP 4.3 or it would have two copies of > the code - one with public keyword and one without? It's not just about Pear. There are plenty of large codebases out there that need to migrate slowly to PHP5. Since public and var have exactly the same meaning in the two versions, I don't see why making public a synonym for var in PHP 4.4 is in any way detrimental. -Rasmus