On Mon, 11 Mar 2019 at 12:35, Nikita Popov <nikita....@gmail.com> wrote:

>
> Removing the ability to use dynamic properties (even excluding stdClass)
> is probably not feasible on a short timetime. However, I think that having
> a directory-scoped declare would also be useful for that, because it allows
> a more gradual migration. You can start with having strict_properties
> default to false and have interested parties opt-in. Then you can flip the
> default to true, while still giving people who rely heavily on it the
> ability to opt-out. Removal would be the final stage where the ability to
> opt-out goes away.
>
>

I think that's actually the best argument I've seen so far. The current
proposal is basically very conservative: a simple, self-contained change,
that even a noob like me was able to implement. The downside of that is
that it doesn't have a long-term vision: there's no clear path to making
all classes "locked" by default.

I agree that the combination of package- or directory-scoped declares, and
a switch that can be both opt-in and opt-out, gives a better future
direction. I just hope we get those things, rather than just having neither
- as happened with "static class", which was rejected partly because "we'll
have function autoloading real soon".

Regards,
-- 
Rowan Collins
[IMSoP]

Reply via email to