Re: Re: [RFC] Namespace-scoped declares, again
| From: | Michał Brzuchalski | Date: | Mon, 29 Jul 2019 10:03:16 +0000 |
| Subject: | Re: Re: [RFC] Namespace-scoped declares, again | ||
| References: | 1 2 3 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-106321@lists.php.net to get a copy of this message | ||
Hi,
niedz., 28 lip 2019 o 05:17 Stanislav Malyshev <smalyshev@gmail.com>
napisał(a):
> > Based on the received feedback, I plan to change this proposal from being
> > "namespace-scoped" to being "directory-scoped" instead. This should
> > both
>
> I don't think it improves much, in my opinion, and it also introduces
> hard dependency in the language on specific placing of files and
> directories - i.e. if you move file on the filesystem, it can actually
> work differently, which was never the case before. Having concepts like
> filenames change the core functionality of the language looks to me like
> an example of leaky abstraction and a hack which may solve a particular
> problem now but at the cost of making the whole design more messy and
> introducing more problems in the future.
>
IMHO it would be impossible to find out what are the boundaries of
namespace scope
or package scope (whatever you call that) symbols without a root namespace
file.
I can imagine some can use explicit require to load library class to skip
scoped declares,
autoloads or whatever lands there.
--
regards / pozdrawiam,
--
Michał Brzuchalski
about.me/brzuchal
brzuchalski.com