Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:38580 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 36336 invoked from network); 24 Jun 2008 14:47:52 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 24 Jun 2008 14:47:52 -0000 Authentication-Results: pb1.pair.com smtp.mail=indeyets@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=indeyets@gmail.com; sender-id=pass; domainkeys=bad Received-SPF: pass (pb1.pair.com: domain gmail.com designates 66.249.92.175 as permitted sender) DomainKey-Status: bad X-DomainKeys: Ecelerity dk_validate implementing draft-delany-domainkeys-base-01 X-PHP-List-Original-Sender: indeyets@gmail.com X-Host-Fingerprint: 66.249.92.175 ug-out-1314.google.com Received: from [66.249.92.175] ([66.249.92.175:58108] helo=ug-out-1314.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id C2/F9-17106-71901684 for ; Tue, 24 Jun 2008 10:47:52 -0400 Received: by ug-out-1314.google.com with SMTP id h3so619411ugf.29 for ; Tue, 24 Jun 2008 07:47:48 -0700 (PDT) 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 :content-transfer-encoding:content-disposition:references; bh=cObz7oWPilAEIECzfjjk4pbtDXQBnBoDuqi9XUaNIsQ=; b=FRy6+Bb4kpqeInNBJQu85dnbyWqSLjd8p/kbAJyBAmdprXk0Cwvn7Xh+xrDNhKHzcg t3RQbpi16U9HaoTgBSYFNYiQ/psC9UIfCq0y3Gr5z58aAtsM6+68YiNHRBxXXdp8IooC jwSAvHvQCq8TgDgj+1W8QA/HNaPg378VejQHY= 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:content-transfer-encoding:content-disposition :references; b=hVm/+JaSF6/d+BUkefCQ0h7SFC8SuuPw7rYRcsJRSfb6ghmDBBdRRn5ftVKqFSqFwx PJbbAeZ0S7FbzLVS0/vrn1PLSTsiFqWSHS9gP/yH4d4vpUwmT0ogIsqCDG4F1O4ExzU5 we+8WicTN2whnHda9dsi+HDARJH+oLDcEg1IY= Received: by 10.67.19.13 with SMTP id w13mr3354383ugi.84.1214318868156; Tue, 24 Jun 2008 07:47:48 -0700 (PDT) Received: by 10.150.158.8 with HTTP; Tue, 24 Jun 2008 07:47:48 -0700 (PDT) Message-ID: Date: Tue, 24 Jun 2008 18:47:48 +0400 To: "Derick Rethans" Cc: "Gregory Beaver" , "Andi Gutmans" , "Stanislav Malyshev" , "Dmitry Stogov" , "internals Mailing List" In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <485BD1C0.8040302@chiaraquartet.net> Subject: Re: [PHP-DEV] simple solution to another namespace conundrum? From: indeyets@gmail.com ("Alexey Zakhlestin") On Tue, Jun 24, 2008 at 6:36 PM, Derick Rethans wrote: > On Fri, 20 Jun 2008, Gregory Beaver wrote: > >> The user is obviously intentionally creating a "DateTime" class, and >> doesn't care about the internal classname in this script. >> >> The attached patch against PHP_5_3 would fix the issue by eliminating >> the check for conflict with CG(class_table) in the global namespace for >> internal classes. It however preserves this check for userspace classes >> so that (for instance) php-src/tests/Zend/ns_030.phpt does not fail. >> The basic idea is that we do have control over the userspace classes we >> include, but have no control over the internal classes. > > I am not so sure this is a good idea. I mean, for the developer that > writes the code it's obvious that his version of DateTime is used. But > for a second developer to come back later this could be a great WTF > factor a few years down the road - wondering why the DateTime > documentation on php.net doesn't match with what the class does. it won't be a serious 'wtf', as on the top of the file, there would be some kind of use MySuperLibrary::DateTime; -- Alexey Zakhlestin http://blog.milkfarmsoft.com/