Re: forward compatibility "public" in 4.4

From: Date: Thu, 16 Jun 2005 07:18:27 +0000
Subject: Re: forward compatibility "public" in 4.4
References: 1 2 3 4 5 6  Groups: php.internals 
Request: Send a blank email to internals+get-16717@lists.php.net to get a copy of this message
Mike Bretz wrote: > Rasmus Lerdorf wrote: > >> What was the reasoning again for not having var be a synonym for public >> in PHP5? It is a bit annoying that a simple PHP4 class using var throws >> a notice in PHP5 when there is technically nothing wrong with it. >> >> -Rasmus > > I personally don't support "forward compatibility" as well. Especially > when talking about a php 4.x tree, which has to be "downward" compatible > as well. Introducing a new synonym allowing to develop "upward" > compatible php code at least breaks this rule. On the other hand I don't > believe that this synonym would help in any way to produce good > perfoming "pre-php5" code. > > Why not make PHP5 not complaining about those php4 "var" definitions at > all? > Maybe a new error level for "deprecated" keywords (and function calls) > would be helpful? and is it a problem to implement such a new error level also with PHP 4.4. for example reporting overwriting $this is not allowed in PHP 5 ? and, when we are at this, what about 'clone' as a dummy-keyword in PHP 4.4 ? -- Sebastian Mendel www.sebastianmendel.de www.sf.net/projects/phpdatetime | www.sf.net/projects/phptimesheet

« previous php.internals (#16717) next »