Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:40623 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 11391 invoked from network); 23 Sep 2008 08:14:00 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 23 Sep 2008 08:14:00 -0000 Authentication-Results: pb1.pair.com header.from=dmitry@zend.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=dmitry@zend.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain zend.com designates 212.25.124.163 as permitted sender) X-PHP-List-Original-Sender: dmitry@zend.com X-Host-Fingerprint: 212.25.124.163 il-gw1.zend.com Windows 2000 SP4, XP SP1 Received: from [212.25.124.163] ([212.25.124.163:8467] helo=il-gw1.zend.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 1C/4E-35835-745A8D84 for ; Tue, 23 Sep 2008 04:14:00 -0400 Received: from ws.home ([10.1.1.1]) by il-gw1.zend.com with Microsoft SMTPSVC(6.0.3790.3959); Tue, 23 Sep 2008 11:14:01 +0300 Message-ID: <48D8A542.1080500@zend.com> Date: Tue, 23 Sep 2008 12:13:54 +0400 User-Agent: Thunderbird 2.0.0.16 (X11/20080723) MIME-Version: 1.0 To: Jochem Maas CC: Greg Beaver , Lupus Michaelis , internals@lists.php.net References: <48D47532.8080102@chiaraquartet.net> <10845a340809201643q59e27211i471e09241f7253b1@mail.gmail.com> <200809202000.38870.larry@garfieldtech.com> <48D66160.40306@chiaraquartet.net> <48D79672.4060208@zend.com> <48D79B9D.2080703@iamjochem.com> <48D7A5C8.7070503@zend.com> <48D7EEE8.2060701@iamjochem.com> In-Reply-To: <48D7EEE8.2060701@iamjochem.com> X-Enigmail-Version: 0.95.7 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 23 Sep 2008 08:14:01.0531 (UTC) FILETIME=[5612F0B0:01C91D54] Subject: Re: [PHP-DEV] solving the namespace conflict issues between function/staticmethod class constant/ns constant From: dmitry@zend.com (Dmitry Stogov) Jochem Maas wrote: > hi Dmirty, > >> >>>> I really don't see a reason to change namespace syntax into a less >>>> intuitive way. >>> I don't think the current implementation is intuitive, the ambiguity >>> issues, >>> (and possibly the name resolution order, although I can't grok what the >>> current >>> state of that is) are rather large WTFs. >>> >>>> Your speed degradation argument isn't truth. The >>>> ambiguity problem exists, but it is just an ability to use php in a >>>> wrong way. Just don't create conflicting names. >>> which begs the question, what was namespaces created for? >>> (that's a serious question because your statement has me truly confused) >>> > > you didn't answer the question (and AFAIC the readme doesn't either). The main reason of namespaces is resolution of name conflicts and ability to use the same names in different scopes. >> >> README.namespaces was committed into PHP_5_3 about year ago. > a 14 month old document which doesn't cover the status quo, > and begins with a disingenuous statement about the problem namespaces > try to > solve (is that really all there is to namespaces? to avoid typing long > class names? Yes, you are right. It's need to be adopted to current situation which might be changed once again... > most people have auto-complete features in their editor to take care of > that 'problem' > and it really doesn't explain why constants or functions exist in > namespaces at all.) I see you point, and you might be satisfied with decision which is going to be final, however from my point of view function and constants must be allowed in namesapaces just because they are parts of the language. Thanks. Dmitry.