Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:92448 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 37393 invoked from network); 19 Apr 2016 11:50:47 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 19 Apr 2016 11:50:47 -0000 Authentication-Results: pb1.pair.com header.from=andre.romcke@ez.no; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=andre.romcke@ez.no; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain ez.no designates 157.56.112.137 as permitted sender) X-PHP-List-Original-Sender: andre.romcke@ez.no X-Host-Fingerprint: 157.56.112.137 mail-am1on0137.outbound.protection.outlook.com Received: from [157.56.112.137] ([157.56.112.137:58978] helo=emea01-am1-obe.outbound.protection.outlook.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 63/80-33122-39B16175 for ; Tue, 19 Apr 2016 07:50:45 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ezno.onmicrosoft.com; s=selector1-ez-no; h=From:To:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=7Vll0hl1PGobawPoYmi7LRho4CouZMxy2CFQg5IoyaM=; b=AhkYl7Ah+u2qf+AesIp8hkIPIzu25o76s8b682+mPrWVpQlIVef0dA4NS8Xjqz+YcpOudmw5cG+LwtRwqxBT5ffor/2JOXPcwWF4zbxHhw7NEOs1Zxx5SGW/SjrgaffJZtZKLGMX16i61qCRCoOJJX5hDn1lF1k6y/x67riQmGs= Received: from AM5PR0701MB1875.eurprd07.prod.outlook.com (10.167.216.24) by AM5PR0701MB1876.eurprd07.prod.outlook.com (10.167.216.25) with Microsoft SMTP Server (TLS) id 15.1.477.5; Tue, 19 Apr 2016 11:50:39 +0000 Received: from AM5PR0701MB1875.eurprd07.prod.outlook.com ([10.167.216.24]) by AM5PR0701MB1875.eurprd07.prod.outlook.com ([10.167.216.24]) with mapi id 15.01.0466.022; Tue, 19 Apr 2016 11:50:39 +0000 To: Lester Caine CC: "internals@lists.php.net" Thread-Topic: [PHP-DEV] Final properties Thread-Index: AQHRjpsLjUTOyIPv1ku7OuTXOI+d1Z97GZwAgAYu9ICAACcngIAAD8mAgAAxcwCAABFKgIADRSMAgAJZQwCAAPwOgIAACYCAgAAOj4CAABfqgIAAmzeAgAAgKYCAAuQzYIAAOLCAgAThPgA= Date: Tue, 19 Apr 2016 11:50:39 +0000 Message-ID: <5F68BFD0-F21A-4ABB-8E98-DF2A6525D0D2@ez.no> References: <5708B197.9020108@php.net> <9C0BBB93-8173-45CF-9636-888B340828FD@ez.no> <57090928.3040905@php.net> <570BD5E6.2000304@fleshgrinder.com> <570DCE46.3020800@gmail.com> <570EA1B7.60903@fleshgrinder.com> <570EA9AF.5060806@gmail.com> <570EB5E5.4050301@fleshgrinder.com> <570EC9F5.50702@gmail.com> <9D0DDAC8-7FE1-40C7-AAE1-60E35AE4C092@ez.no> <570F6723.8020608@lsces.co.uk> <884C80C8-7A81-4095-8718-1EB5E335DF5A@ez.no> <5712039D.9060208@lsces.co.uk> In-Reply-To: <5712039D.9060208@lsces.co.uk> Accept-Language: nb-NO, de-DE, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: lsces.co.uk; dkim=none (message not signed) header.d=none;lsces.co.uk; dmarc=none action=none header.from=ez.no; x-ms-exchange-messagesentrepresentingtype: 1 x-originating-ip: [46.19.18.34] x-ms-office365-filtering-correlation-id: c75d5653-93e9-48ec-4fd1-08d36848d45e x-microsoft-exchange-diagnostics: 1;AM5PR0701MB1876;5:gdAVXxSxv4kU1RIpSP0TWJWPsXskY9BnlieEBA3XhL8DA6h0IiO1IRF9UcRKSnRig/6JNInS9dcnLbD6JXMEQTzRmU26fsS7DtGfL44Rffhxn83W497KEDvNL3MiqOkr4ZKuFwD5vN8MyY05bzJTNQ==;24:NzWxjx/zaKAi/OPTNFO8VotSfECrvtAT0ON4cSRxIvx/J2BR3JmzjgXpjJsixwZ51JB0gwxLqTeQC7jTQUff5tXDy5cPPMrMwsuvkYPbrOw=;7:/2WmSCHpu0W2xIl4p6yIkxAIDTwkbE5f8MKavnDx8XdZ1OZkAoRcN2qdwOR7bj792e9dmuqJ51odn07+8WrhNb1uE0ycq3xMQKWGsXQQhmH2OeMYhmTberhcSLgiRlsyOUSKm6UE4Mc+FQBQZyTgJF6lWQqT7Fdby9s0RdV+3Clg27Xe0eeXyehoCeQO1y/5 x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:AM5PR0701MB1876; x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:; x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(9101521026)(601004)(2401047)(8121501046)(5005006)(3002001)(10201501046);SRVR:AM5PR0701MB1876;BCL:0;PCL:0;RULEID:;SRVR:AM5PR0701MB1876; x-forefront-prvs: 0917DFAC67 x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(6009001)(24454002)(586003)(3846002)(3660700001)(54356999)(110136002)(50986999)(4326007)(76176999)(189998001)(1096002)(1220700001)(6116002)(102836003)(3280700002)(5004730100002)(93886004)(2900100001)(2950100001)(19580395003)(19580405001)(33656002)(87936001)(11100500001)(86362001)(106116001)(77096005)(15975445007)(66066001)(74482002)(10400500002)(122556002)(83716003)(82746002)(81166005)(5008740100001)(36756003)(92566002)(2906002);DIR:OUT;SFP:1102;SCL:1;SRVR:AM5PR0701MB1876;H:AM5PR0701MB1875.eurprd07.prod.outlook.com;FPR:;SPF:None;MLV:sfv;LANG:en; spamdiagnosticoutput: 1:23 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="Windows-1252" Content-ID: Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: ez.no X-MS-Exchange-CrossTenant-originalarrivaltime: 19 Apr 2016 11:50:39.7850 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: f606c019-4e72-4e2e-8583-51197302e349 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM5PR0701MB1876 Subject: Re: [PHP-DEV] Final properties From: andre.romcke@ez.no (=?Windows-1252?Q?Andr=E9_R=F8mcke?=) > On 16 Apr 2016, at 11:19 , Lester Caine wrote: >=20 > On 16/04/16 06:56, Andr=E9 R=F8mcke wrote: >>>> This actually summarises many of the problems all of these 'extras' ar= e >>>> creating for very little gain. >>>>=20 >>>> 'Seconds' is a 'Traditional Property' so is untyped and if accessed as= a >>>> value from some OS's will be a floating point number[...] >> It wasn't really the example I intended to point to, it does not represe= nt the cases me and others refer to. I was linking to it for the possible s= olution to handle type and immutability. >>=20 >> Examples for the latter: >> https://en.m.wikipedia.org/wiki/Value_object >=20 > Working from and SQL base ... the schema provides both validation beyond > simply 'int' or 'float' and 'read only' all simply extensions to the > basic variable returned. readonly in this case is more about application logic and not db logic. If you want to take a swing at it a more relevant example would be to just = ask everyone to use get() and in case of writable properties set($value) and stop asking about expanding the language to cover the use c= ases and hence simplify use. >=20 >>>> I don't see how the idea of 'optimizing' the compiled code has any >>>> bearing on handling a 'typed property' when one has to have an object = to >>>> contain even the simple of type information? >>=20 >> What is this regarding? >=20 > People have been claiming they need to be able to identify the type in > order to optimize the compiled code. [=85..] True, for me is more about the benefits in user land. There are lots of cas= es where those claims won=92t be true, as in scalars changing types. So eve= n with type hints it will still need some sort of tracing JIT compiler that= uses type info from todays runtime to machine compile hot spots, the type = hints will merely make sure the type is somewhat more predictable. And even= then you=92ll need to account for possible type misses and sometimes have = to pop back to interpreter effectively loosing time. All of which Javascrip= t has done for years and continue on to do, afaik latests on that is https:= //webkit.org/blog/5852/introducing-the-b3-jit-compiler/ =20 But even if discussing that would be neat, and it=92s relevance since there= have been discussions on using LLVM with PHP over the years. This thread i= s not really about type, it=92s about readonly properties or whatever you w= ould like to call them :)