Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:33958 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 27306 invoked by uid 1010); 12 Dec 2007 04:25:36 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 27291 invoked from network); 12 Dec 2007 04:25:36 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 12 Dec 2007 04:25:36 -0000 Authentication-Results: pb1.pair.com header.from=dohpaz@gmail.com; sender-id=pass; domainkeys=bad Authentication-Results: pb1.pair.com smtp.mail=dohpaz@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 64.233.162.239 as permitted sender) DomainKey-Status: bad X-DomainKeys: Ecelerity dk_validate implementing draft-delany-domainkeys-base-01 X-PHP-List-Original-Sender: dohpaz@gmail.com X-Host-Fingerprint: 64.233.162.239 nz-out-0506.google.com Received: from [64.233.162.239] ([64.233.162.239:58122] helo=nz-out-0506.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id E7/FC-38526-FB26F574 for ; Tue, 11 Dec 2007 23:25:35 -0500 Received: by nz-out-0506.google.com with SMTP id x7so53662nzc.38 for ; Tue, 11 Dec 2007 20:25:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; bh=VgvxjdsrQ+ta9bkvQn4ybN/u0OSXDXuruIe/k+deGKk=; b=oXI2JR+9QiyboRu1uaRVeJA8Hl2CTPD6tKUG1ZvYHhnuiWeW0ttBTexaTGgsbrKSTINSavnMkMadM1cKNOGHtcjD4APtS/p6D72yrdvCHwv0iMci2LK6AoWilEkewzIgErvy8NEH+9BoFB5cQx7/EUNbvdFbGVT2+c6BKkewZNE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; b=GxfsM7ypfpxGSiqPmMF9rrzZTTItmZ3jqCjTJ+4LP2TAnyGJtAEqPwUmPMSmxoqjuDQdjBVOTqrNRBx2piI5g8VYrOqmB5OHUfFmSlACopTzZUZuIteSAJ62gNmyzJIrHcpjKXzOAxkflC1WSifc3Bfzz4YMOaEzlo5F4HxK24o= Received: by 10.142.109.16 with SMTP id h16mr31003wfc.117.1197433532149; Tue, 11 Dec 2007 20:25:32 -0800 (PST) Received: by 10.142.180.15 with HTTP; Tue, 11 Dec 2007 20:25:32 -0800 (PST) Message-ID: Date: Tue, 11 Dec 2007 23:25:32 -0500 To: "Gregory Beaver" Cc: "internals Mailing List" In-Reply-To: <475F1984.603@chiaraquartet.net> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_30455_11986874.1197433532126" References: <475F1984.603@chiaraquartet.net> Subject: Re: [PHP-DEV] namespace improvements to be committed very soon - final review From: dohpaz@gmail.com ("Ken Stanley") ------=_Part_30455_11986874.1197433532126 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline On Dec 11, 2007 6:13 PM, Gregory Beaver wrote: > The example above shows that imported names are reset at each namespace > declaration. There is no prohibition on this code: > > namespace one; { > use Blah::A; > // code > } > namespace two; { > use Foo::A; > // code > } > ?> > > Users who wish to use brackets may do so. The performance penalty > imposed by using brackets is minor for some cases, and for users who are > following the recommended practice of 1 namespace per file, the syntax > is ideal. My question is that if using the above code already incurs a perf penalty, then why not just go ahead and include true support for braces in namespaces. Unless there is an additional penalty that I'm missing, the only difference between true braces and the above is that the above looks like a cheap hack (note: the use the of phrase "cheap hack" is in no way meant to demean the hard work of the people involved with the namespace implementation, and is the sole opinion of the poster :)). -- It looked like something resembling white marble, which was probably what it was: something resembling white marble. -- Douglas Adams, "The Hitchhikers Guide to the Galaxy" ------=_Part_30455_11986874.1197433532126--