Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:85024 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 68733 invoked from network); 16 Mar 2015 11:18:39 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 16 Mar 2015 11:18:39 -0000 Authentication-Results: pb1.pair.com smtp.mail=derick@php.net; spf=unknown; sender-id=unknown Authentication-Results: pb1.pair.com header.from=derick@php.net; sender-id=unknown Received-SPF: unknown (pb1.pair.com: domain php.net does not designate 82.113.146.227 as permitted sender) X-PHP-List-Original-Sender: derick@php.net X-Host-Fingerprint: 82.113.146.227 xdebug.org Linux 2.6 Received: from [82.113.146.227] ([82.113.146.227:51347] helo=xdebug.org) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id F2/8C-00492-D0CB6055 for ; Mon, 16 Mar 2015 06:18:37 -0500 Received: from localhost (localhost [IPv6:::1]) by xdebug.org (Postfix) with ESMTPS id 97515E202F; Mon, 16 Mar 2015 11:18:34 +0000 (GMT) Date: Mon, 16 Mar 2015 11:18:34 +0000 (GMT) X-X-Sender: derick@whisky.home.derickrethans.nl To: Xinchen Hui cc: Pierre Joye , PHP internals In-Reply-To: Message-ID: References: User-Agent: Alpine 2.11 (DEB 23 2013-08-11) MIME-Version: 1.0 Content-Type: MULTIPART/MIXED; BOUNDARY="8323329-1845358157-1426504714=:4205" Subject: Re: [PHP-DEV] About declare(strict_types = 1) From: derick@php.net (Derick Rethans) --8323329-1845358157-1426504714=:4205 Content-Type: TEXT/PLAIN; charset=UTF-8 Content-Transfer-Encoding: QUOTED-PRINTABLE On Mon, 16 Mar 2015, Xinchen Hui wrote: > On Mon, Mar 16, 2015 at 5:00 PM, Pierre Joye wrote= : > > > > On Mar 16, 2015 4:29 PM, "Xinchen Hui" wrote: > >> > >> that means, I need to add a lots of (int) while I try to call a > >> function in a library which is not written by myself. > >> > >> is that right? > > > > You got the answer but one thing bothers me a lot right now. > > > > How did you vote against this rfc while missing the core point of it (a= fter > > actually having a strict mode)? > as I said, > " > acutaly, I believe in most applications, they will still keep this off.. >=20 > so why we introduce such thing? > " > I don't like strict_types at all.. To be frank, I don't think "I don't like this" is a terribly good reason=20 to vote against (or for something). What is important is how many people=20 would actually benefit from a feature, without it causing issues for=20 others. I am certainly no fan of the "declare" *syntax*, but I do know,=20 from talking at conferences that many many developers would like to see=20 scalar type hints in some way =E2=80=94 both weak (mode 1 of the STHv5 RFC)= , and=20 strict (mode 2). It even caters for people that don't want to use them=20 at all, as they can simply not use them. I also know, that without a=20 dual mode, it seems very unlikely for scalar type hints to make it=20 into PHP 7, and I don't think that is what users want. As this is our=20 *best* bet, I can only vote "yes". cheers, Derick --8323329-1845358157-1426504714=:4205--