Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:40378 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 78476 invoked from network); 8 Sep 2008 21:57:52 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 8 Sep 2008 21:57:52 -0000 Authentication-Results: pb1.pair.com smtp.mail=chuck@horde.org; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=chuck@horde.org; sender-id=pass Received-SPF: pass (pb1.pair.com: domain horde.org designates 75.144.171.129 as permitted sender) X-PHP-List-Original-Sender: chuck@horde.org X-Host-Fingerprint: 75.144.171.129 technest.org Received: from [75.144.171.129] ([75.144.171.129:54696] helo=technest.org) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 27/E6-46475-EDF95C84 for ; Mon, 08 Sep 2008 17:57:51 -0400 Received: by technest.org (Postfix, from userid 33) id E9CE37F08F; Mon, 8 Sep 2008 17:57:47 -0400 (EDT) Received: from ip65-47-144-166.z144-47-65.customer.algx.net (ip65-47-144-166.z144-47-65.customer.algx.net [65.47.144.166]) by technest.org (Horde Framework) with HTTP; Mon, 08 Sep 2008 17:57:47 -0400 Message-ID: <20080908175747.15286prnn4siyubk@technest.org> Date: Mon, 08 Sep 2008 17:57:47 -0400 To: internals@lists.php.net References: <48C59D5C.4050507@chiaraquartet.net> In-Reply-To: <48C59D5C.4050507@chiaraquartet.net> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; DelSp="Yes"; format="flowed" Content-Disposition: inline Content-Transfer-Encoding: quoted-printable User-Agent: Dynamic Internet Messaging Program (DIMP) H3 (2.0-cvs) Subject: Re: [PHP-DEV] namespace examples (solving name resolution order issues) From: chuck@horde.org (Chuck Hagenbuch) Quoting Greg Beaver : > Part 3: > judgment of value > > Current approach: > advantages: > 1) internal classes resolve very fast > disadvantages: > 1) potential unexpected name resolution to internal class when > namespaced classname exists > > New approach: > advantages: > 1) code runs the same regardless of load order or autoload > disadvantages: > 1) serious performance slowdown on each internal class name resolution In my opinion the unexpected name resolution to internal classes is a =20 serious flaw in the current namespace implementation, and will cause a =20 lot of confusion or (in my case) avoiding namespaces altogether. The =20 clincher for me is that the performance ramifications can be solved =20 with the exact same workaround that is currently necessary for all =20 user-defined classes (use ::Exception) AND - in PHP user-defined =20 classes are far more common and numerous than internal classes. So I would be extremely happy to see this change go into PHP 5_3. =20 Thanks, Greg! -chuck