Re: No Namespaces & Vortex
Jean-Christophe Michel <jc.michel-/aRvmaKoZxNWk0Htik3J/[email protected]>
| Newsgroups | gmane.comp.lib.binarycloud.devel |
|---|---|
| Message-ID | <[email protected]> |
Manuel Holtgrewe wrote:
> Hi
>
> Since there are no namespaces in PHP we will soon hit a problem with
> duplicate class names (Item is something widely used, I believe). I
> think we should add a rule that class names have to be prefixed with the
> package's name, i.e: StoreItem, MyAppItem, FooItem.
>
> Other ideas/thoughts?
Leads to huge names. We should have a naming convention.
And I propose to use the fact that php authorize any char [128-255] in
var names to choose one as namespace separator: can be trema ¨, tilde ~,
mdash —, midpoint ·, or some else easily accessible from all keyboards.
Examples:
store¨Item
store~Item
store—Item
store·Item
I personnally like the midpoint.
--
Jean-Christophe Michel
_______________________________________________
dev mailing list
dev-PnctHDZWAvB/Cz2I37pSEPZ4XP/[email protected]
http://lists.binarycloud.com/mailman/listinfo/dev