On Sun, Jul 15, 2012 at 6:21 PM, Rasmus Lerdorf <ras...@lerdorf.com> wrote:

> On 07/15/2012 06:03 PM, Anthony Ferrara wrote:
>
> > Additionally, DateTime is a class in core. Do any functions throw
> > exceptions?
>
> Nope, and note that if you call those same DateTime functions
> procedurally they don't use exceptions. So yes, changing PHP to start
> throwing exceptions from procedurally-called functions would be a major
> change.
>

What about an approach like PDO, where the password functions would
generate errors by default, but could be configured to throw exceptions?
The ugliest aspects of this idea are the requirement for another function
(password_set_option?) and hidden state. On the plus side, if you stick
with errors for now it could be implemented down the road and be fully BC.

Reply via email to