News Feed
Jobs Feed
Sections




News Archive
Community News:
Namespaces in PHP6
July 06, 2007 @ 11:10:00

Spurred on by a recent post to the php-dev mailing list by Dmitry Stogov the ever-popular "namespaces discussion" has surged back to the top of everyone's list. Dmitry proposed a patch for PHP6 that would easily implement namespaces for the upcoming version.

All class and function names inside are automatically prefixed with namespace name. Inside namespace, local name always takes precedence over global name. It is possible to use the same namespace in several PHP files. The namespace declaration statement must be the very first statement in file.

The general idea is to provide an easy separation of functionality but to keep things accessible at any level (in scope, in parent scope, etc). He's included code in his mailing list post to illustrate how it would all work.

Several others in the PHP community have jumped on and are already talking about this new proposal:

1 comment voice your opinion now!
namespace php6 patch declaration mailinglist phpdev namespace php6 patch declaration mailinglist phpdev


blog comments powered by Disqus

Similar Posts

HowTo Forge: How To Harden PHP5 With Suhosin On Fedora 7

Christian Wenz's Blog: Zeev on PHP

DynamicWebPages.de: PHP 5.1.3RC1 Released

Stefan Esser's Blog: Suhosin Updates - Improved Randomness & LAZY Symbol Loading

Lukas Smith's Blog: back Is your chosen PHP framework on the PHP primary tester mailinglist?


Community Events











Don't see your event here?
Let us know!


zendframework2 composer unittest testing opinion community development framework code podcast example interview introduction tool series release language functional object conference

All content copyright, 2013 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework