On 15 March 2015 at 08:42, Pavel Kouřil <pajou...@gmail.com> wrote: > Sure, per-file is better than ini setting, but better doesn't mean > good (because it is still a pretty bad approach). The ini setting at > least has the option to be turned off in code once everyone realizes > it was a bad idea (register_globals via htaccess, for instance), but > PHP would be stuck with the declare for a long time - this is not an > easily revertable change, once PHP ships with it. >
The declaration is turned on with code. This is no different to changing an ini setting with code, except that it can't be configured globally in advance. Existing code is unaffected. I'm not sure where your "not easily revertible" argument is grounded. It's incredibly easy to add/remove declarations at the top of a file. The two groups (people who want strong typing and weak typing) will > not work *together* though. And it will be a nightmare for everyone > working on multiple projects from mulitple clients or so. > Pure FUD. Sorry but there is no evidence to back this up. PHP will IMHO never be strongly-typed by default. Probably. > The best approach to have some reasonable > type rules is to progressively "strenghten" the rules (as Zeev's RFC > tried to do so, but he probably did two steps in one RFC and that's > what people dislike about it?). You think the best approach is to progressively and continually break working code between versions? How is this approach acceptable ever? > I think that PHP's type system would > get to some "equilibrium" by this - people wanting stronger typing > would tried to introduce it and people wanting weaker one would > balance it and eventually there could be a point on which both sides > could agree on. > No, they would never reach agreement. I sincerely hope the Dual Mode RFC doesn't pass. I can't imagine the > RFC being good for the userland developers in the long run. Apologies again, but I think you don't really understand what is being proposed in this RFC. Proponents of strict typing get exactly what they want, they can develop their library or entire project in strict mode if they want, and if someone wants to use this project or library, but themselves want to use weak mode, _nothing breaks_.