Daniel,

On Sun, Jul 15, 2012 at 8:20 PM, Daniel Convissor <
dani...@analysisandsolutions.com> wrote:

> Hi Anthony:
>
> > But I agree with your larger point. The only problem with it is that it
> > would take an engine wide shift to do.
>
> How does using exceptions in this new extension require an "engine wide
> shift?"  DateTime already uses exceptions, no problem.
>

DateTime only uses the generic Exception class. If I was going to support
this implementation, it would use typed exceptions so the handling code
could have a chance to determine the type of the error...

http://lxr.php.net/xref/PHP_TRUNK/ext/date/php_date.c#2448

Not a show stopper, but from my perspective it would be inconsistent and
not much better to do that than leave the default error handling in place
until we take a larger look at errors vs exceptions for the core as a
whole...

Additionally, DateTime is a class in core. Do any functions throw
exceptions?

Anthony

Reply via email to