Stas Malyshev wrote:
mmh.. how much breakage did you want.

PEAR::isError is basically is_a($input, 'PEAR_Error'); it's been like
that for>  8 years....

So, PEAR has a bug, if it passes non-object argument to is_a, as previously is_a
was only documented (and actually still is) as accepting objects. The fact that
this bug remained for 8 years is very sad, but it doesn't cease to be a bug.

If I am reading things right, is_a was only designed to handle an object, so feeding it a mixed parameter in isError was always wrong? As far as I can see, on the whole, the PEAR code only ever feeds an object and feeding it a string would have to be a real error? So there are a number of actions here all of which are potentially wrong, and PEAR should return an error if $input is not a valid object rather than relying on undocumented actions simply to fail?

--
Lester Caine - G8HFL
-----------------------------
Contact - http://lsces.co.uk/wiki/?page=contact
L.S.Caine Electronic Services - http://lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk//
Firebird - http://www.firebirdsql.org/index.php

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

Reply via email to