> Davey Shafik wrote: > >> I believe that using the PHP namespace is the right way to go, and look >> forward to seeing code like this in the future: >> >> <?php >> namespace Dshafik; >> >> use PHP\Attribute; >> >> <<Attribute>> >> class Foo { }
> Chase Peeler wrote: > >> I don't think PhpAttribute is a bad name [...] nor is it logically >> inconsistent with other Php* named classes. > Rowan Tommins wrote: > >> One of the things I dislike about "PhpAttribute" is that it's still really >> generic - I know I'm writing PHP, so it feels like broken Hungarian notation >> ("class FooClass extends BarInterface") rather than an actual name. I’ve been trying to think through other naming schemes that could set a good precedent for these discussions as we move forward, since I think this will continue to be a topic of discussion. So, I tried to think of alternate schemes, such as introducing a root-level attributes namespace (e.g. `Attributes\Attribute` and `Attributes\CompilerAttribute`, or `PhpAttributes\Attribute`, etc.), but that would see arbitrary namespaces proliferate in the core, and the potential for collisions with userland code would be even greater. I’m starting to come around to Davey’s way of thinking here, but I don’t know if I’m quite there yet. Perhaps we change `PhpCompilerAttribute` to `CompilerAttribute` and rename `Attribute`/`PhpAttribute` to `UserlandAttribute`? It seems that’s the distinction we’re attempting to make with these names. Cheers, Ben
signature.asc
Description: Message signed with OpenPGP