Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:20393 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 86956 invoked by uid 1010); 25 Nov 2005 12:52:46 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 86941 invoked from network); 25 Nov 2005 12:52:46 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 25 Nov 2005 12:52:46 -0000 X-Host-Fingerprint: 70.85.46.36 unknown Received: from ([70.85.46.36:34744] helo=prohost.org) by pb1.pair.com (ecelerity 2.0 beta r(6323M)) with SMTP id 36/00-56276-C1907834 for ; Fri, 25 Nov 2005 07:52:46 -0500 Received: (qmail 10662 invoked from network); 25 Nov 2005 12:52:41 -0000 Received: from prohost.org (HELO ?127.0.0.1?) (70.85.46.36) by prohost.org with SMTP; 25 Nov 2005 12:52:41 -0000 Message-ID: <43870917.5070409@prohost.org> Date: Fri, 25 Nov 2005 07:52:39 -0500 User-Agent: Mozilla Thunderbird 1.0.6 (Windows/20050716) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Christian Schneider CC: Lukas Smith , Marcus Boerger , PHP Developers Mailing List References: <7.0.0.16.2.20051124161240.0573e640@zend.com> <20051125034515.6fefa4e2@localhost.localdomain> <43867C6C.2010209@prohost.org> <20051125040950.26305e08@localhost.localdomain> <43869FC5.4060708@lerdorf.com> <20051125075501.79718ee6@localhost.localdomain> <1132903004.9936.25.camel@localhost.localdomain> <1086017308.20051125091648@marcus-boerger.de> <01.D8.11378.05EC6834@pb1.pair.com> <1946534082.20051125100920@marcus-boerger.de> <4386D5C6.8040802@php.net> <4386E355.7020901@cschneid.com> In-Reply-To: <4386E355.7020901@cschneid.com> X-Enigmail-Version: 0.93.0.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] Re: PHP 5.1 (Or How to break tousands of apps out there) From: ilia@prohost.org (Ilia Alshanetsky) Christian Schneider wrote: > As has been pointed out before this isn't only a PEAR problem: Every > single application out there defining a Date class has to be changed if > the core adds a class with the same name. Defining classes/function with generic names will always be a problem as they may end up conflicting with same constructs from other libraries or PHP itself. > Is this common? One of our running gags here is that every project ends > up adding its own set of date formating/conversion functions/classes at > some point. So unless people are prefixing all local classes there is a > rather good chance of having a class named Date in quite some projects. To design future proof code projects for the most part prefix all their functions/classes to prevent naming conflicts. > Section [7] of CODING_STANDARDS Naming Conventions states that "The > class name should be prefixed with the name of the 'parent set'" but at > the same time lists "Curl" as good. Now my question is whether the > prefixing should be enforced (at least when a common name like Date is > used)? It makes little sense to have a class called curl_curl, when it comes to functions the coding standard applied and all functions have a prefix. Ilia