Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:38501 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 32031 invoked from network); 21 Jun 2008 20:23:13 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 21 Jun 2008 20:23:13 -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 38.99.98.18 cause and error) X-PHP-List-Original-Sender: greg@chiaraquartet.net X-Host-Fingerprint: 38.99.98.18 beast.bluga.net Linux 2.6 Received: from [38.99.98.18] ([38.99.98.18:36109] helo=mail.bluga.net) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id EA/64-26505-F236D584 for ; Sat, 21 Jun 2008 16:23:12 -0400 Received: from mail.bluga.net (localhost.localdomain [127.0.0.1]) by mail.bluga.net (Postfix) with ESMTP id 98E8DC13566; Sat, 21 Jun 2008 13:23:15 -0700 (MST) Received: from [192.168.0.106] (CPE-76-84-4-101.neb.res.rr.com [76.84.4.101]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.bluga.net (Postfix) with ESMTP id C1DF2C13563; Sat, 21 Jun 2008 13:23:14 -0700 (MST) Message-ID: <485D6373.9000902@chiaraquartet.net> Date: Sat, 21 Jun 2008 15:24:19 -0500 User-Agent: Thunderbird 2.0.0.14 (X11/20080505) MIME-Version: 1.0 To: Jessie Hernandez CC: internals@lists.php.net, Andi Gutmans , Stanislav Malyshev , Dmitry Stogov References: <485BD1C0.8040302@chiaraquartet.net> <485D5696.4070408@gmail.com> In-Reply-To: <485D5696.4070408@gmail.com> X-Enigmail-Version: 0.95.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Virus-Scanned: ClamAV using ClamSMTP Subject: Re: simple solution to another namespace conundrum? From: greg@chiaraquartet.net (Gregory Beaver) Jessie Hernandez wrote: > Hi Greg, > > How is this different from my original proposal > (http://news.php.net/php.internals/34097, > http://news.php.net/php.internals/34097)? > > The patch committed only affects non-namespaced code, your proposal affected all code. In other words, this always works: whereas this: had the potential to fail with fatal error without code change on upgrade to a newer PHP version that creates the "Closure" class. The committed patch addresses only this shortcoming, and changes nothing else. In other words, this: still prints "Exception" and not "Foo::Exception". Additionally, unlike your proposal, all existing namespace tests still pass with the behavior change. 2 new tests were added, 1 to test the relaxed behavior, and 1 to test that this next example is a fatal error because definition of Foo::Closure is in the same file as the "use Blah::Closure": Greg