Re: Why do disabled functions / classes generate a WARNING.
| From: | Stan Vass | Date: | Fri, 03 Aug 2012 16:36:21 +0000 |
| Subject: | Re: Why do disabled functions / classes generate a WARNING. | ||
| References: | 1 2 3 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-62015@lists.php.net to get a copy of this message | ||
a php function/operation can raise more than one warning, how would you handle that?
with exceptions you would only get the first one.
another issue is that with the current error handling model a call can trigger a non-fatal error
and still return some data.
with exeptions you can't do that.
so changing our internal error handling isn't as easy to start throwing ErrorException-s, it
would require much more workthan that.
Yes it is a bit more work than that. For example include issues two errors on include failure, I
mute one of them and turn the other into an exception, which is one of the behaviors you've
mentioned. There are ways to fix everything, but you have to be specific, if you want me to be
specific as well.
Either way I'm trying to give a practical solution you can implement today. Aside from
practicality, I do also support the idea that accessing disabled symbols should be a fatal error,
not a warning.
Stan