Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:58164 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 12643 invoked from network); 27 Feb 2012 17:38:13 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 27 Feb 2012 17:38:13 -0000 Authentication-Results: pb1.pair.com smtp.mail=ircmaxell@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=ircmaxell@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.216.49 as permitted sender) X-PHP-List-Original-Sender: ircmaxell@gmail.com X-Host-Fingerprint: 209.85.216.49 mail-qw0-f49.google.com Received: from [209.85.216.49] ([209.85.216.49:62296] helo=mail-qw0-f49.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id CD/21-40985-48FBB4F4 for ; Mon, 27 Feb 2012 12:38:12 -0500 Received: by qafi29 with SMTP id i29so372333qaf.8 for ; Mon, 27 Feb 2012 09:38:10 -0800 (PST) Received-SPF: pass (google.com: domain of ircmaxell@gmail.com designates 10.224.72.138 as permitted sender) client-ip=10.224.72.138; Authentication-Results: mr.google.com; spf=pass (google.com: domain of ircmaxell@gmail.com designates 10.224.72.138 as permitted sender) smtp.mail=ircmaxell@gmail.com; dkim=pass header.i=ircmaxell@gmail.com Received: from mr.google.com ([10.224.72.138]) by 10.224.72.138 with SMTP id m10mr12271495qaj.95.1330364290302 (num_hops = 1); Mon, 27 Feb 2012 09:38:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; bh=XitQJ2AaNPcz+dNG5TETfDFTCe+FU2Xs/GXkNzOioMo=; b=dXgDdm0CZaKzD/TP/RrEGuoHLnw/vt9yagwXGmVA9utOFrRxfLUTRiy5e3q8goOKOh sj/KzCa7mwbQW6c4eb8oqJFbtB0zShRy9np1GO7SUdtcxRaXvqDu2u/g6QnDhAUkPrUz 1Icp9MVLVCD9kxLbsOK5J6N5kUcX4TrS51hoc= MIME-Version: 1.0 Received: by 10.224.72.138 with SMTP id m10mr10326702qaj.95.1330364290127; Mon, 27 Feb 2012 09:38:10 -0800 (PST) Received: by 10.229.166.202 with HTTP; Mon, 27 Feb 2012 09:38:10 -0800 (PST) In-Reply-To: References: <1330357150.2159.30.camel@guybrush> Date: Mon, 27 Feb 2012 12:38:10 -0500 Message-ID: To: Ferenc Kovacs Cc: Michael Morris , "internals@lists.php.net" Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Subject: Re: [PHP-DEV] Scalar type hinting From: ircmaxell@gmail.com (Anthony Ferrara) > no, it is: "come back after you did your homework, and you can provide ne= w > arguments to the discussion" To be completely fair, I did homework on this. I went back to 2000 on marc.info's archives and read almost all of the 400 posts matching the search http://marc.info/?l=3Dphp-internals&w=3D2&r=3D13&s=3Dstrict+typing&q= =3Db and a bunch of the posts on http://marc.info/?l=3Dphp-internals&w=3D2&r=3D54&s=3Dtype+hinting&q=3Db The vast majority of what I found were quite good arguments for including the feature. I found quite a bit of "this was discussed to death, do your homework and provide new arguments". What's odd, is that one of the earliest on-topic threads that I found (2007: http://marc.info/?l=3Dphp-internals&m=3D119514660125258&w=3D2 ) had this as the third reply. The only on-topic discussion that I found prior to that was in 2006 (almost exactly 1 year prior: http://marc.info/?l=3Dphp-internals&m=3D116257685415135&w=3D2 ). Discussed to death. Yet only one time before (discussing a specific patch)= ... And the opponents still said no... There were also quite a few problems identified with scalar hinting and auto-casting vs strict erroring. However, there were also solutions proposed to nearly each and every one of them. And the opponents still said no... It has been brought up time and time again. Solutions have been proposed which have no fundimental issues (inconsistencies, problematic operations - such as references, etc)... And the opponents instead said "this has been discussed to death, no"... Please can you stop saying "this has been discussed to death". To be frank, don't stop the discussion because you don't like the idea. It has been discussed to death. But the discussion has only really ever involved people who are for it. The opponents by and large have used two arguments: "It has been discussed already, so no" and "don't make PHP into Java". There has been some discussion of technical merit and problem resolution by opponents, but finding it is VERY difficult among all the down trodding commentary. So let me make a plea: If you don't like this feature, and you can explain from a TECHNICAL perspective why, please do so! If you don't like the feature, and are going to lean on "It's not Java", or "We've discussed this to death already", please don't... And to be fair: "and you can provide new arguments to the discussion" has already happened quite a bit (dating back the past 5 years), but those arguments were ignored or overruled for political reasons. Anthony On Mon, Feb 27, 2012 at 11:55 AM, Ferenc Kovacs wrote: > On Mon, Feb 27, 2012 at 5:16 PM, Michael Morris w= rote: > >> So the official response is "get lost"? >> >> > no, it is: "come back after you did your homework, and you can provide ne= w > arguments to the discussion" > > > >> I don't know about the internals implications. =A0But from an external >> API standpoint I see no problem in allowing programmers who want to >> strictly enforce a variable's datatype to do so. =A0Legacy code would >> not be affected unless it was trying to use the new reserved word >> "strict" >> >> > it was discussed before, strict typing tends to be "viral", in the sense > that the developer using a lib which enforces method signatures using typ= e > hinting can either: > - write a lot of boiler plate code to make sure that he/she is passing th= e > expected types (notice that strict typing would pass that burden to the a= pi > consumer, which is against the Generous on input, strict on output > paradigm, plus it would generate much more work, as there are always more > consumers than producers) > - or simply passing those requirements up in the call chain, which is les= s > work, but affects even more code, and in the end, turns the whole app int= o > strict typing. > > -- > Ferenc Kov=E1cs > @Tyr43l - http://tyrael.hu