Re: PEAR2 standards: anything good at all?
| From: | Alexey Borzov | Date: | Mon, 16 Jul 2007 08:45:49 +0000 |
| Subject: | Re: PEAR2 standards: anything good at all? | ||
| References: | 1 2 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-47517@lists.php.net to get a copy of this message | ||
Hi,
Lukas Kahwe Smith wrote:
We are talking 1-2 lines of unnecessary code. Exception classes tend to be much smaller than current PEAR.php containing PEAR_Error. They are also perfect candidates for an exception to one-class-per-file rule.require_once controversy was already covered a lot here, my opinion is: * slow require_once in APC is a problem of APC, not PEAR. APC developers are aware of it and are solving it, so sometime our optimizations may become counter-productive. * require_once is faster without APC. If we're targeting PHP6 which will (supposedly) have APC built in, why aren't we using namespaces, too, going instead for PEAR2_Obnoxiously_Long_Class_Names?only if you do not load unnecessary code, which you are likely to do. or otherwise you end up combining a require_once with every new. take for example the various exception classes etc.
A broken enough user __autoload() implementation will break PEAR2 installation. That'll remain true, BTW, even if we provide our own __autoload().* Anyone else smelling a reincarnation of PEAR_Error here?No, I smell added flexibility at the expense of "forcing" users to add an ultra simple __autoload() (or spl variant thereof) that simply does your beloved require_once.