Re: [RFC][DISCUSSION] Deprecation of fallback to root scope
| From: | Levi Morrison | Date: | Sat, 03 Feb 2018 16:31:26 +0000 |
| Subject: | Re: [RFC][DISCUSSION] Deprecation of fallback to root scope | ||
| References: | 1 2 3 4 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-101753@lists.php.net to get a copy of this message | ||
On Sat, Feb 3, 2018 at 3:22 AM, Wes <netmo.php@gmail.com> wrote:
> No idea, I'm not really sure what's the difference between E_STRICT and
> E_DEPRECATED.
> Yeah the shim is just a rough POC (completely forgot that define() can
> define in namespaces).
> Nicolas Grekas on twitter also suggested that we should introduce
> function_alias() that works like class_alias().
> With that the shim would be literally a couple of lines long.
From our manual:
> E_NOTICE : Run-time notices. Indicate that the script encountered something that could indicate
> an error, but could also happen in the normal course of running a script.
> E_DEPRECATED: Run-time notices. Enable this to receive warnings about code that will not work
> in future versions.
> E_STRICT: Enable to have PHP suggest changes to your code which will ensure the best
> interoperability and forward compatibility of your code.
In my opinion we should emit E_STRICT until we know when the feature
will be removed. At that point we can promote it to E_DEPRECATED and
specifically cite when it will be removed. In any case, E_NOTICE does
not seem appropriate.