Re: "PHP" namespace?

From: Date: Wed, 30 Jul 2014 07:19:45 +0000
Subject: Re: "PHP" namespace?
References: 1 2 3  Groups: php.internals 
Request: Send a blank email to internals+get-76263@lists.php.net to get a copy of this message
Hi, On Wed, Jul 30, 2014 at 5:47 AM, Yasuo Ohgaki <yohgaki@ohgaki.net> wrote: > Hi Andrey, > > On Mon, Jul 28, 2014 at 4:42 PM, Andrey Andreev <narf@devilix.net> wrote: >> >> This would be a major BC break, that couldn't possibly happen in PHP >> 5.x and IMO is way too radical even for PHP 6/7. > > > It wouldn't be major BC, but minor. > > Most compatible way is to allow namespace alias to \ (root) and simply > override > existing functions. There isn't BC with this. PHP allows it already when it > is done > one by one. > > If we would like to have clean \ (root) namespace optionally, it's matter of > adding > a setting. > > What make you think it a major BC? > > Regards, > > -- > Yasuo Ohgaki > yohgaki@ohgaki.net If you'd alias the root namespace to \php or whatever, what's the point in all of it? I don't see such, so I assumed that you meant to require developers to explicitly import whatever they need in the root namespace. And that would be a major BC break. Cheers, Andrey.

« previous php.internals (#76263) next »