Newsgroups: php.internals,php.internals Path: news.php.net Xref: news.php.net php.internals:34404 php.internals:34405 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 53715 invoked by uid 1010); 4 Jan 2008 14:26:31 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 53700 invoked from network); 4 Jan 2008 14:26:31 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 4 Jan 2008 14:26:31 -0000 X-Host-Fingerprint: 74.225.168.223 adsl-225-168-223.mia.bellsouth.net Received: from [74.225.168.223] ([74.225.168.223:13681] helo=localhost.localdomain) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 35/B3-29353-5124E774 for ; Fri, 04 Jan 2008 09:26:29 -0500 To: internals@lists.php.net,Markus Fischer Message-ID: <477E4212.5000307@gmail.com> Date: Fri, 04 Jan 2008 09:26:26 -0500 User-Agent: Thunderbird 1.5.0.12 (X11/20070530) MIME-Version: 1.0 CC: internals@lists.php.net References: <476878B4.8000200@gmail.com> <4778E18A.3080605@fischer.name> In-Reply-To: <4778E18A.3080605@fischer.name> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Posted-By: 74.225.168.223 Subject: Re: Interfaces name "Interface", was: [PHP-DEV] Re: Idea for namespacelookup resolution From: jrhernandez05@gmail.com (Jessie Hernandez) Hi Markus, Thanks for testing out the patch! Has anyone else had a chance to test it out? I think this is a good solution to the naming conflict issue that is currently present with namespaces, but I'd love to hear other's opinions/experiences on this. -- Jessie Hernandez Zend Certified Engineer (http://zend.com/zce.php?c=ZEND006359&r=222727282) Markus Fischer wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Hi, > > I started a scratch project with this patch and working with it seems > intuitive so far. > > My only question at the moment is the following, however I guess it > isn't specific to your NS patch then to Dmitry's: > > My current practice to declare an interface and provide concrete > implementation was like this: > > file: Foo/Bar/Interface.php > interface: Foo_Bar_Interface > > Now this gets problematic: > > file: Foo/Bar/Interface.php > namespace: Foo::Bar; > interface: Interface > > The last one doesn't work, because the source actually looks like: > > interface Interface { > > which gives > > syntax error, unexpected T_INTERFACE, expecting T_STRING > > I tried something like > > namespace Foo; > interface Bar::Interface; > > but that gives another parser error about the :: > > syntax error, unexpected T_PAAMAYIM_NEKUDOTAYIM, expecting '{' > > Is there any chance for Rescue for this, instead of changing the naming > scheme? > > thanks, > - - Markus > > -----BEGIN PGP SIGNATURE----- > Version: GnuPG v1.4.6 (MingW32) > Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org > > iD8DBQFHeOGK1nS0RcInK9ARAmsFAKC98h2eUH+CusL/h8X4pT5A3EH3SwCg4Jxg > M+S0xyhNEbc/BzLxSY/UO0M= > =jR9j > -----END PGP SIGNATURE-----