Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:96593 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 56004 invoked from network); 24 Oct 2016 13:54:37 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 24 Oct 2016 13:54:37 -0000 X-Host-Fingerprint: 137.50.156.90 oa-edu-156-90.wireless.abdn.ac.uk Received: from [137.50.156.90] ([137.50.156.90:28810] helo=localhost.localdomain) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 04/4E-28528-C921E085 for ; Mon, 24 Oct 2016 09:54:36 -0400 Message-ID: <04.4E.28528.C921E085@pb1.pair.com> To: internals@lists.php.net References: Date: Mon, 24 Oct 2016 14:54:32 +0100 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:43.0) Gecko/20100101 Firefox/43.0 SeaMonkey/2.40 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Posted-By: 137.50.156.90 Subject: Re: [RFC][DISCUSSION] Object type hint From: ajf@ajf.me (Andrea Faulds) Hi, MichaƂ Brzuchalski wrote: > I would like to initiate discussion for Object typehint RFC > https://wiki.php.net/rfc/object-typehint I like this proposal. We already have an object type internally for the same reasons (functions acting on a generic object), so it makes sense to extend this to userland which may want to do the same kinds of things. One potential benefit is that functions can be more generic. I imagine there's some functions out there typed against \stdClass which could really accept any object if given the option. Best of luck. -- Andrea Faulds https://ajf.me/