Re: [RFC] Namespace syntax decision
| From: | Johannes Schlüter | Date: | Sat, 22 Mar 2008 21:32:30 +0000 |
| Subject: | Re: [RFC] Namespace syntax decision | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-36340@lists.php.net to get a copy of this message | ||
Hi,
On Fri, 2008-03-21 at 22:36 +0100, Marcus Boerger wrote:
> PHP is very close to Java and C++ in terms of Syntax. And many of our users
> are familiar with one or even both of them. Also we have a tendency to
> especially take syntax from those two or be in line with those two
> languages. That said I see two ways:
>
> 1) namespace foo { }
>
> 2) package foo;
>
> I favor 1) if we allow namespace nesting and 2) if not. The current way of
> nesting is very confusing:
> namespace foo; namespace bar;
I said in some previous post I won't like multiple namespaces per file
using the 2nd syntax. So imo: either on ns per file and the 2nd syntax
or allow multiple and use brackets. And then I prefer the latter.
johannes