Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:20988 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 1204 invoked by uid 1010); 2 Dec 2005 07:10:40 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 1189 invoked from network); 2 Dec 2005 07:10:39 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 2 Dec 2005 07:10:39 -0000 X-Host-Fingerprint: 64.233.162.199 zproxy.gmail.com Linux 2.4/2.6 Received: from ([64.233.162.199:42119] helo=zproxy.gmail.com) by pb1.pair.com (ecelerity 2.0 beta r(6323M)) with SMTP id F2/C5-14828-E63FF834 for ; Fri, 02 Dec 2005 02:10:38 -0500 Received: by zproxy.gmail.com with SMTP id i11so461163nzi for ; Thu, 01 Dec 2005 23:10:35 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=ZQP2qL069M0XNdFamO6Xp7ICreOzI88+vhR6ENJ2LzCLF2G3b8NH4+DbVAFNMrcmAVEbmkYeP3pP3EoAqNsbe0KSJ6EfmSp3YmbhD5Te2gm/+vwtI+18pV0UFYQ78GAkECcTt50LI9545m1ScaRD9rEXvICaqEVkAx1BNvZ1lFM= Received: by 10.65.38.14 with SMTP id q14mr1284468qbj; Thu, 01 Dec 2005 23:10:00 -0800 (PST) Received: by 10.65.242.3 with HTTP; Thu, 1 Dec 2005 23:09:58 -0800 (PST) Message-ID: Date: Fri, 2 Dec 2005 09:09:58 +0200 To: internals@lists.php.net In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: Subject: Re: [PHP-DEV] phpnamespaces.org! From: manchokapitancho@gmail.com (Marian Kostadinov) First I must say - a nice job:) The namespaced version works fine. I found just 3 problems (things I don't like): 1.Import statements are allowed only in the beginning of the script. 2.Global function calls are not allowed in a namespace. 3.The example below does not work. Anyway, the patch seems to be stable. Also ::: is veeery long. I wrote it a lot of times and usually I got :: instead of ::: 2005/12/1, Jessie Hernandez : > Thanks to several people, the phpnamespaces.org site is up and contains t= he > latest namespace patch, pre-patched tarballs and Win32 zip, example scrip= ts, > and links to namespace-related news! If you are interested in seeing > namespaces in PHP, or are curious to see the progress of this development= , > then please visit http://www.phpnamespaces.org. You are encouraged to joi= n > the mailing list to keep up-to-date and to post any questions/feedback on > the current patch. > > Soon a detailed explanation on the internals of the patch will be added > along with documentation for its new features. > > The idea for the site was not mine, but several people have contributed > their time, effort, and resources to make this happen. Special thanks goe= s > out to Hans, Ian, and Tony for obtaining the domain name, server, and add= ing > the initial content. > > > Regarding the latest version of the patch, there are several items I'd li= ke > to get feedback on so as to finish the patch (mostly scoping/resolution): > > 1) Importing of namespace constants (it looks like this was present in on= e > of the PHP 5.0 betas, so I'm working on adding this). > > 2) How will symbols be resolved inside namespaces? If a class "A" exists = in > namespace "N", and a global class "A" also exists, then by referencing "A= ", > what should happen? Should the namespaced "A" be used? If so, then the > global "A" cannot be accessed from the namespace. Is this OK? These rules > would need to be the same and affects the following contexts: > > - Extends: class B extends A{} > - Type hints for functions/methods inside the namespace > - Method/function bodies inside a namespace > > 3) If a symbol is imported (having an alias or not) and there is a global > symbol that has that same name, what is the correct behavior? Should the > global symbol be ignored? Should an error occur? Should the global take > precedence? > > 4) For now the patch uses the ":::" separator. ":" cannot be used, as it > conflicts with the ternary (EVEN if we only leave classes inside namespac= es) > and "::" causes ambiguity. The separator is now in a #define, so if worst > comes to worst and ":::" cannot be used/is not desired, then the change t= o > "\" will be easy. > > I'll post any additional issues as I encounter them. > > > Regards, > > Jessie Hernandez > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > >