Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:44595 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 27913 invoked from network); 1 Jul 2009 19:04:20 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 1 Jul 2009 19:04:20 -0000 Authentication-Results: pb1.pair.com header.from=stas@zend.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=stas@zend.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain zend.com designates 63.205.162.117 as permitted sender) X-PHP-List-Original-Sender: stas@zend.com X-Host-Fingerprint: 63.205.162.117 us-mr1.zend.com Linux 2.4/2.6 Received: from [63.205.162.117] ([63.205.162.117:34202] helo=us-mr1.zend.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 11/28-24906-333BB4A4 for ; Wed, 01 Jul 2009 15:04:20 -0400 Received: from us-gw1.zend.com (us-ex1.zend.net [192.168.16.5]) by us-mr1.zend.com (Postfix) with ESMTP id BF21CE12C3; Wed, 1 Jul 2009 11:53:14 -0700 (PDT) Received: from [192.168.16.83] ([192.168.16.83]) by us-gw1.zend.com with Microsoft SMTPSVC(6.0.3790.3959); Wed, 1 Jul 2009 12:04:53 -0700 Message-ID: <4A4BB330.8060104@zend.com> Date: Wed, 01 Jul 2009 12:04:16 -0700 Organization: Zend Technologies User-Agent: Thunderbird 2.0.0.22 (Windows/20090605) MIME-Version: 1.0 To: Paul Biggar CC: Ilia Alshanetsky , PHP internals References: <4A4BA5C8.1020204@zend.com> <4A4BAE7B.3020601@zend.com> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 01 Jul 2009 19:04:53.0188 (UTC) FILETIME=[D0C0A840:01C9FA7E] Subject: Re: [PHP-DEV] RFC: Type hinting revisited for PHP 5.3 From: stas@zend.com (Stanislav Malyshev) Hi! > I agree. We won't be able to use an int type for something which > should take an int. That might not matter in user code, but if we > cannot actually type hint internals functions then its a problem. Internal functions have types, however parameters of different types are usually converted, not rejected. > My feeling is that scalars should be automatically coerced to the > correct type, if it makes sense to do so. (ie reject non-numeric That (coercion) is what internal functions do, but not what the proposed patch does (except for "numeric" hint). -- Stanislav Malyshev, Zend Software Architect stas@zend.com http://www.zend.com/ (408)253-8829 MSN: stas@zend.com