Re: [VOTE] Undefined Variable Error Promotion
| From: | Sara Golemon | Date: | Tue, 15 Mar 2022 19:32:49 +0000 |
| Subject: | Re: [VOTE] Undefined Variable Error Promotion | ||
| References: | 1 2 3 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-117339@lists.php.net to get a copy of this message | ||
On Tue, Mar 15, 2022 at 2:08 PM Miguel Rosales <mrosalessueiro@gmail.com>
wrote:
> > The RFC states:
> >
> > | If the code does not currently emit a “Warning: Undefined variable
> > | $varname” then it is out of scope for this RFC. This RFC does NOT
> > | apply to array indexes.
> >
> > That explicitly excludes undefined array indexes, and apparently also
> > excludes undefined properties (which raise "Warning: Undefined
property:")
> >
> AFAIU error promotion for undefined properties has already been covered
> by the Deprecate Dynamic Properties RFC
> <https://wiki.php.net/rfc/deprecate_dynamic_properties>,
> which will
> start throwing errors in 9.0.
>
What I'm hearing is that we also need an RFC for promoting 'Undefined
index...' warnings to Errors as well.
-Sara