On Wed, Apr 29, 2020 at 2:51 PM Côme Chilliet < come.chill...@fusiondirectory.org> wrote:
> Le mardi 28 avril 2020, 18:59:22 CEST Benas IML a écrit : > > Could you provide any examples as to where '\Attribute' is being used in > the > > wild? I haven't seen a single project that has an Attribute class and > uses the > > global namespace. > > We do use an Attribute class in FusionDirectory: > https://gitlab.fusiondirectory.org/fusiondirectory/fd/-/blob/1.4-dev/include/simpleplugin/class_Attribute.inc > > I’d expect a lot of projects to have an Attribute class, since there are > things named attributes in lots of contexts. > Great! You have discovered a nice opportunity to finally move your code into the FusionDirectory namespace. PHP reserves (de facto if not de jure) the global namespace for it's own purposes. If you want to place classes in the global namespace, without prefixing them, that's fine, but please don't complain if there are clashes. Nikita