Kris Craig wrote on 12/02/2015 21:45:
Since it's very common for environments to display E_WARNING but not E_NOTICE, some devs-- particularly those who are less experienced in PHP-- can end up wasting a lot of time trying to chase down the behavior because they're not seeing any errors.

If people have turned off E_NOTICE, there is presumably something in that level that they don't want to see; giving them that choice is the whole point of having multiple reporting levels in the first place. Without a clear definition of what should be in each level, there's a risk of inflation setting in, with advocates of each message saying why people should see it even if they have E_NOTICE turned off.

The alternative, which I've tried to picture before, is a more customisable system based on types of message rather than severity - so that a user who has a lot of $foo[$new_key][$new_sub_key] = $value in their code can suppress E_ACCESSING_NONEXISTENT_ARRAY_KEY, and a user who has a lot of $foo[unquote_key] can suppress E_UNDECLARED_CONSTANT_USED_AS_STRING (obviously with better names than that!). That way important messages which you definitely want to fix don't get drowned in the noise of things which you know you should get around to fixing one day but are working as designed right now.

Regards,
--
Rowan Collins
[IMSoP]

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to