Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:26405 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 47426 invoked by uid 1010); 7 Nov 2006 14:46:31 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 47410 invoked from network); 7 Nov 2006 14:46:30 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 7 Nov 2006 14:46:30 -0000 Authentication-Results: pb1.pair.com smtp.mail=cschneid@cschneid.com; spf=permerror; sender-id=unknown Authentication-Results: pb1.pair.com header.from=cschneid@cschneid.com; sender-id=unknown Received-SPF: error (pb1.pair.com: domain cschneid.com from 195.141.85.117 cause and error) X-PHP-List-Original-Sender: cschneid@cschneid.com X-Host-Fingerprint: 195.141.85.117 uf1.search.ch Linux 2.4/2.6 Received: from [195.141.85.117] ([195.141.85.117:37232] helo=smtp.rim.ch) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id CA/92-30081-24C90554 for ; Tue, 07 Nov 2006 09:46:29 -0500 Received: from localhost (localhost [127.0.0.1]) by verksam.search.ch (Postfix) with ESMTP id 093B93A0692; Tue, 7 Nov 2006 15:46:18 +0100 (CET) Received: from unknown by localhost (amavisd-new, unix socket) id client-XXEaNwXr; Tue, 7 Nov 2006 15:46:17 +0100 (CET) Received: by verksam.search.ch (Postfix, from userid 65534) id 1A2AF3A06A3; Tue, 7 Nov 2006 15:46:17 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.1.0 (2005-09-13) on verksam.search.ch X-Spam-Level: X-Spam-Status: No, score=-1.1 required=5.0 tests=BAYES_05 autolearn=ham version=3.1.0 Received: from [192.168.1.72] (ultrafilter-i [192.168.85.2]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by verksam.search.ch (Postfix) with ESMTP id 6525F3A0692; Tue, 7 Nov 2006 15:46:16 +0100 (CET) Message-ID: <45509C37.1030401@cschneid.com> Date: Tue, 07 Nov 2006 15:46:15 +0100 User-Agent: Thunderbird 1.5.0.7 (X11/20060911) MIME-Version: 1.0 To: RQuadling@GoogleMail.com Cc: php internals LIST References: <7f3ed2c30611031000j2dc48a6amb7f04c8011442b56@mail.gmail.com> <282B7D4B-DC15-4ABC-95A6-C03F766C19B7@prohost.org> <27664.208.195.234.246.1162844322.squirrel@www.l-i-e.com> <10845a340611070126hdd3cfe1v4f62a37d98f620e1@mail.gmail.com> In-Reply-To: <10845a340611070126hdd3cfe1v4f62a37d98f620e1@mail.gmail.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at search.ch Subject: Re: [PHP-DEV] [PATCH] Scalar type hinting ;) From: cschneid@cschneid.com (Christian Schneider) ini_set('humour', "On"); Richard Quadling wrote: > Type hinting is part of the documentation. Sure, hungarian notation of > variable names (where the type is represented within the variable name > itself) is a good start, but when you get to things like a 4d array of I wouldn't have expected anyone to use hungarian notation with PHP. But then again that's what the Spanish inquisition would probably use to torture nowadays and who expects the Spanish inquisition? (-:C On the other hand it is easy to do it in PHP: Just prefix every variable with "m" :-) > The loose typing > of PHP is great, but as mentioned by Richard Lynch, we have to more or > less move away from it for user input and DB input. Error: Incompatible use of constant 'we' > Maybe for V6 type hinting for scalars could be available, but output > purely E_NOTICE. Really make them just a hint. A suggestion. This will ini_set('humour', "Off"); All type hints warnings should be E_STRICT, not E_NOTICE IMHO. If that's the case then you can add as many bondage feature as you wish as long as they don't slow down non-strict code ;-) - Chris