Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:41169 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 90651 invoked from network); 16 Oct 2008 22:08:01 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 16 Oct 2008 22:08:01 -0000 Authentication-Results: pb1.pair.com header.from=greg@chiaraquartet.net; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=greg@chiaraquartet.net; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain chiaraquartet.net from 208.83.222.18 cause and error) X-PHP-List-Original-Sender: greg@chiaraquartet.net X-Host-Fingerprint: 208.83.222.18 unknown Linux 2.6 Received: from [208.83.222.18] ([208.83.222.18:42611] helo=mail.bluga.net) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id E7/D6-12818-F3BB7F84 for ; Thu, 16 Oct 2008 18:08:00 -0400 Received: from mail.bluga.net (localhost.localdomain [127.0.0.1]) by mail.bluga.net (Postfix) with ESMTP id 86B1BD0F46A; Thu, 16 Oct 2008 15:07:50 -0700 (MST) Received: from pcp063035pcs.unl.edu (pcp063035pcs.unl.edu [129.93.125.92]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.bluga.net (Postfix) with ESMTP id 4A090D0F406; Thu, 16 Oct 2008 15:07:46 -0700 (MST) Message-ID: <48F7BB37.3080502@chiaraquartet.net> Date: Thu, 16 Oct 2008 17:07:51 -0500 User-Agent: Thunderbird 2.0.0.6 (Macintosh/20070807) MIME-Version: 1.0 To: Chris Stockton CC: internals@lists.php.net, Steph Fox References: <48F653FF.5010106@chiaraquartet.net> <48F75FA1.7020505@zend.com> <0C55B977-3835-4CB0-A23B-8AA684B71C18@pooteeweet.org> <48F772CD.80600@zend.com> <48F775DD.5010202@chiaraquartet.net> <48F777B4.2050609@gmail.com> <025a01c92fb6$95d8b350$3ffc1f3e@foxbox> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Virus-Scanned: ClamAV using ClamSMTP Subject: Re: [PHP-DEV] my last attempt at sanity with namespaces From: greg@chiaraquartet.net (Greg Beaver) Chris Stockton wrote: > I have been watching the namespace conversations for months and I can not > get my head around this fixation on a new separator. Other languages get by > without separate resolution syntax, why not solve these ambiguities through > rules of precedence like everyone else? Throw possible ambiguity warnings if > we don't mind looking ahead for the performance hit and give users the > ability to alias their namespaces with AS when conflicts do occur they can > be easily fixed. > using BadNamedLib as BetterNamedLib; > using BadNamedLib; > > Resolve using :: as a separator, have some simple rules and document them, > first namespace's loaded classes takes precedence over the last. Constansts > are more important then classes, or vice versa. Document the determined > precedence. Giving users a tool to alias namespaces solves a lot of the > namespace resolution issues. Hi Chris, This is actually option #3 on the list of solutions at http://wiki.php.net/rfc/namespaceissues Steph: can you catalog this as a vote for it? Greg