Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:85180 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 3280 invoked from network); 18 Mar 2015 11:05:48 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 18 Mar 2015 11:05:48 -0000 Authentication-Results: pb1.pair.com header.from=florian@margaine.com; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=florian@margaine.com; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain margaine.com from 209.85.223.178 cause and error) X-PHP-List-Original-Sender: florian@margaine.com X-Host-Fingerprint: 209.85.223.178 mail-ie0-f178.google.com Received: from [209.85.223.178] ([209.85.223.178:34295] helo=mail-ie0-f178.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id FD/62-22462-90C59055 for ; Wed, 18 Mar 2015 06:05:47 -0500 Received: by iecsl2 with SMTP id sl2so34687141iec.1 for ; Wed, 18 Mar 2015 04:05:42 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=PHhQaUQ6NtVH6iVCJ7FUAxWjtLkPuqbI3cKNejan/aM=; b=Me0utSwrNFLMXS2B3p7RzEDlb+SIljTS0ryfWr8DZLpjmS9ohQhAECeCjQcPVpqL+U m1w8uxHnt/44PS0TJ0k4Escp1fPRxjRiP6g18B2Dl/IxVAUtrBdxC4lBqqQavWrNCv1x MyDvwgT/qeLVPMCn5BpQVTuC160gHBipR3/GGFOj9DNT0/oNw/2y3rN5ISNJV5EnsngN Usmq/guN/28zw3WtNNhH8hK89bfFyUmiYu/TW5rOsU3kGFTaDgyXdMtFNzSOvHfy7Rqn mpTI7P8881M70jWxkM+63eNjO5jMElrgPHss+HbXGMRq6/x/Vl0Lk155TlNxjoDuzQnb VYvA== X-Gm-Message-State: ALoCoQnBC/XnYseFr7+MNtO/+psccVpL9PD7DzkZHaE4/+eV8H9E7jV8JpaG9z4f3IIgS3tMhXKJ MIME-Version: 1.0 X-Received: by 10.107.128.226 with SMTP id k95mr41040082ioi.73.1426676742657; Wed, 18 Mar 2015 04:05:42 -0700 (PDT) Received: by 10.107.143.83 with HTTP; Wed, 18 Mar 2015 04:05:42 -0700 (PDT) X-Originating-IP: [90.52.148.128] Received: by 10.107.143.83 with HTTP; Wed, 18 Mar 2015 04:05:42 -0700 (PDT) In-Reply-To: References: Date: Wed, 18 Mar 2015 12:05:42 +0100 Message-ID: To: =?UTF-8?Q?Pavel_Kou=C5=99il?= Cc: Pierre Joye , Anthony Ferrara , PHP internals Content-Type: multipart/alternative; boundary=001a113f9ae474c1e805118e10a9 Subject: Re: [PHP-DEV] [RFC][Accepted] Scalar Type Declarations V0.5 From: florian@margaine.com (Florian Margaine) --001a113f9ae474c1e805118e10a9 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Hi, Le 18 mars 2015 11:06, "Pavel Kou=C5=99il" a =C3=A9cri= t : > > On Wed, Mar 18, 2015 at 11:01 AM, Pierre Joye wrote: > > > > On Mar 18, 2015 4:56 PM, "Pavel Kou=C5=99il" wrote= : > >> > >> On Mon, Mar 16, 2015 at 10:03 PM, Anthony Ferrara > >> wrote: > >> > All, > >> > > >> > Voting has been closed on the scalar type declarations v0.5 RFC: > >> > > >> > https://wiki.php.net/rfc/scalar_type_hints_v5 > >> > > >> > At a final score of 108:48, it has been accepted for PHP 7. > >> > > >> > Thank you. > >> > > >> > Anthony > >> > > >> > -- > >> > PHP Internals - PHP Runtime Development Mailing List > >> > To unsubscribe, visit: http://www.php.net/unsub.php > >> > > >> > >> Hello, > >> > >> how will these examples work btw? > >> > >> // a.php > >> >> declare(strict_types=3D1); > >> function foo($fn) { > >> $fn("1"); > >> }; > >> > >> // b.php > >> >> require 'a.php'; > >> foo(function (int $a) { return $a * 2; }); > >> > >> > >> > >> // c.php > >> >> function foo($fn) { > >> $fn("1"); > >> }; > >> > >> // d.php > >> >> declare(strict_types=3D1); > >> require 'c.php'; > >> foo(function (int $a) { return $a * 2; }); > >> > >> I can't find this in the RFC. I'd intuitively expect error in the > >> first example and the second one to work OK. > >> > >> But at the same time, if there will be an error in the first example, > >> it is IMHO a huge flaw with this RFC. :/ > > > > Git clone, compile, try, report. > > > > It sounds pretty straight forward to me instead of asking the same questions > > (in various form but it ends to the same answer). > > > > And the patch should be applied sooner rather than later. So we can fix bugs > > if there are actual ones in the current implementation. > > Hello, > > if I had time to set up the compilation of PHP on Windows, I'd do it - > but I don't. I wanted to try it myself via http://3v4l.org/, but it > unfortunately doesn't support multiple files. You can emulate multiple files support by using eval(). > > Regards > Pavel Kouril > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > Cheers, Florian Margaine --001a113f9ae474c1e805118e10a9--