Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:33983 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 77190 invoked by uid 1010); 13 Dec 2007 01:20:27 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 77175 invoked from network); 13 Dec 2007 01:20:27 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 13 Dec 2007 01:20:27 -0000 Authentication-Results: pb1.pair.com smtp.mail=jeff@procata.com; spf=permerror; sender-id=unknown Authentication-Results: pb1.pair.com header.from=jeff@procata.com; sender-id=unknown Received-SPF: error (pb1.pair.com: domain procata.com from 207.58.169.145 cause and error) X-PHP-List-Original-Sender: jeff@procata.com X-Host-Fingerprint: 207.58.169.145 vps.procata.net Linux 2.5 (sometimes 2.4) (4) Received: from [207.58.169.145] ([207.58.169.145:57478] helo=vps.procata.net) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 1A/05-34780-BD880674 for ; Wed, 12 Dec 2007 20:20:27 -0500 Received: from c-76-112-12-49.hsd1.mi.comcast.net ([76.112.12.49] helo=[192.168.1.102]) by vps.procata.net with esmtp (Exim 4.63) (envelope-from ) id 1J2ckI-0004fK-M2; Wed, 12 Dec 2007 20:20:18 -0500 Cc: internals Message-ID: <6D0F3834-16E8-46C1-9D3E-8A588BF1A5A6@procata.com> To: Ralph Schindler In-Reply-To: <47606C70.3050202@smashlabs.com> Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Apple Message framework v915) Date: Wed, 12 Dec 2007 20:20:11 -0500 References: <47606C70.3050202@smashlabs.com> X-Mailer: Apple Mail (2.915) X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - vps.procata.net X-AntiAbuse: Original Domain - lists.php.net X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - procata.com Subject: Re: [PHP-DEV] Namespace access modifiers From: jeff@procata.com (Jeff Moore) Hello Ralph, I don't think properties are the appropriate level to specify namespace based access modifiers. I do think that a coarse-grained access restriction on a class by class basis might be. public class Foo {} // Default private class Foo {} (protected is meaningless because there is no inheritance for namespaces.) In principle, I like the idea of adding an access modifier for classes to distinguish between a namespace's public interface and its private features. But, when do you check for access violations of class names? On use? On new? What about esoteric things like reflection and the callback pseudo-type? I just don't see how it could work in practice. Best Regards, Jeff On Dec 12, 2007, at 6:19 PM, Ralph Schindler wrote: > Since everyone is in the "namespace" frame of mind, is there a > possibility of a "namespace" access modifier? > > The way I envision this working is that if for example: > > namespace Foo; > > class Bar { > nsprotected $_someProperty = null; > } > > (or some other equivalent grammer) > > Would allow the property Foo::Bar::$_someProperty to be accessed > from any class that has implemented a class from the Foo namespace. > > Reaching for straws or is this a possibility? > > -ralph > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > > >