Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:77270 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 16734 invoked from network); 16 Sep 2014 19:09:47 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 16 Sep 2014 19:09:47 -0000 Authentication-Results: pb1.pair.com smtp.mail=php@tutteli.ch; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=php@tutteli.ch; sender-id=pass Received-SPF: pass (pb1.pair.com: domain tutteli.ch designates 80.74.154.78 as permitted sender) X-PHP-List-Original-Sender: php@tutteli.ch X-Host-Fingerprint: 80.74.154.78 ns73.kreativmedia.ch Linux 2.6 Received: from [80.74.154.78] ([80.74.154.78:59975] helo=hyperion.kreativmedia.ch) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 7D/28-64534-8FA88145 for ; Tue, 16 Sep 2014 15:09:46 -0400 Received: (qmail 7103 invoked from network); 16 Sep 2014 21:09:41 +0200 Received: from cm56-129-238.liwest.at (HELO RoLaptop) (86.56.129.238) by ns73.kreativmedia.ch with (AES128-SHA encrypted) SMTP; 16 Sep 2014 21:09:41 +0200 To: "'Andrea Faulds'" , "'Levi Morrison'" Cc: "'internals'" References: <74D45E97-4C96-41FA-B824-BCEBA056C654@ajf.me> In-Reply-To: Date: Tue, 16 Sep 2014 21:09:33 +0200 Message-ID: <001101cfd1e1$c1f2df00$45d89d00$@tutteli.ch> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-Mailer: Microsoft Outlook 14.0 Thread-Index: AQL6iJtCQAzQy02K2ulPik/onvJC9wLFSCauAXGZf0wB4Js5spl971Fg Content-Language: de-ch Subject: AW: [PHP-DEV] Renaming type-hints to something else? From: php@tutteli.ch ("Robert Stoll") > -----Urspr=FCngliche Nachricht----- > Von: Andrea Faulds [mailto:ajf@ajf.me] > Gesendet: Dienstag, 16. September 2014 17:26 > An: Levi Morrison > Cc: internals > Betreff: Re: [PHP-DEV] Renaming type-hints to something else? >=20 >=20 > On 16 Sep 2014, at 16:24, Levi Morrison wrote: >=20 > > On Tue, Sep 16, 2014 at 9:16 AM, Andrea Faulds wrote: > >> > >> The general concept should be called Optional Type Declarations, to replace =93Type Hinting". They are type declarations, > and they are optional. Thus the name. For the things themselves, = they=92re just Type Declarations, to replace =93Type Hints". > > > > My worry about "optional type declarations" is that once a type is > > present it isn't optional anymore. Could be confusing and I am = unsure > > if that's any better than a "type hint". > > > > If we change it, maybe just call them "type declarations". I think > > just referring to them as "types" could be too ambiguous. >=20 > I agree. Let=92s just call them =93Type Declarations=94 then. > -- I would argue "type declaration" is wrong as well since it is not a type declaration as it is known in other languages where the type declaration = is binding. IMO it is more a "type check". Consider the following function foo(Bar $b){ $b =3D 1; //$b is not a Bar at all }