Lukas Kahwe Smith wrote:
> 
> On 13.03.2009, at 00:39, Andrei Zmievski wrote:
> 
>> Christian Schneider wrote:
>>> Things gettings reserved at a later stage (like originally keywords, now
>>> namespaces) can lead to a big deal of frustration. Therefore I think it
>>> is crucial to have a clear naming guide now.
>>> And these guidelines have to be noticed by everybody who starts to use
>>> namespaces so they have to be placed prominently.
>>> Personally I'd even prefer them to be enforced in code so they can't be
>>> missed.
>>> Removing restrictions later on causes less trouble so I wouldn't mind
>>> too much if a couple of namespaces (or namespace prefixes) are reserved
>>> but never used.
>>
>> Just a gentle reminder to make sure we don't miss this..
> 
> 
> So where are we at here?
> If nobody proposes something, this will just slide by ..

I propose reserving PHP.  extensions can be PHP\extname (i.e. class
PHP\Phar, or for extensions with multiple levels of hierarchy
PHP\PDO\mysql etc.)

Alternately, we forbid namespaces in extensions, and thus users can
guarantee no conflict with PHP internals simply by using them.

Anything else will lead to insanity very quickly.  Either we'll get
wonderful conflicts or no way to figure out in advance what namespaces
are OK.

Ilia's suggestion of reserving any extension, current or future, as a
namespace makes it impossible to predict what namespaces should not be
used in userspace, and as we know, extensions can have literally any
name.  This, in my opinion, is no option at all, as we need to be able
to know whether names we choose can be safely used with future versions
of PHP.

Greg

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to