Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:58093 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 64870 invoked from network); 26 Feb 2012 21:00:44 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 26 Feb 2012 21:00:44 -0000 Authentication-Results: pb1.pair.com smtp.mail=keisial@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=keisial@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.212.170 as permitted sender) X-PHP-List-Original-Sender: keisial@gmail.com X-Host-Fingerprint: 209.85.212.170 mail-wi0-f170.google.com Received: from [209.85.212.170] ([209.85.212.170:35549] helo=mail-wi0-f170.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 25/B3-40985-C7D9A4F4 for ; Sun, 26 Feb 2012 16:00:44 -0500 Received: by wibhm4 with SMTP id hm4so2827246wib.29 for ; Sun, 26 Feb 2012 13:00:41 -0800 (PST) Received-SPF: pass (google.com: domain of keisial@gmail.com designates 10.180.92.229 as permitted sender) client-ip=10.180.92.229; Authentication-Results: mr.google.com; spf=pass (google.com: domain of keisial@gmail.com designates 10.180.92.229 as permitted sender) smtp.mail=keisial@gmail.com; dkim=pass header.i=keisial@gmail.com Received: from mr.google.com ([10.180.92.229]) by 10.180.92.229 with SMTP id cp5mr22118102wib.8.1330290041228 (num_hops = 1); Sun, 26 Feb 2012 13:00:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=GGv1aWlBoiQvwNUqsjTbWftUBI+mKSNJ6ySadVcjcBM=; b=kuzYck2Um/jVqVPyxz7OOnozW2DvlrXIDreQrV2dqk+47Mr2zDCKSfzuJAwIr1gsYC eGtLpxWBexRfOPve8FBNp6NUB5NTjfn2pUVnfQWLnWYqwhBjWCbqq5Shzy7ZQG9LDuhU 4VJe1Dgpv+y+O1b8rSwTvLwahQY7ICnKCsf3o= Received: by 10.180.92.229 with SMTP id cp5mr17625521wib.8.1330290041178; Sun, 26 Feb 2012 13:00:41 -0800 (PST) Received: from [192.168.1.26] (33.Red-83-44-158.dynamicIP.rima-tde.net. [83.44.158.33]) by mx.google.com with ESMTPS id by4sm11697093wib.3.2012.02.26.13.00.39 (version=SSLv3 cipher=OTHER); Sun, 26 Feb 2012 13:00:40 -0800 (PST) Message-ID: <4F4A9E9D.3080404@gmail.com> Date: Sun, 26 Feb 2012 22:05:33 +0100 User-Agent: Thunderbird MIME-Version: 1.0 To: Anthony Ferrara CC: internals@lists.php.net References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] Object Casting - An Alternative to Type Hinting From: keisial@gmail.com (=?ISO-8859-1?Q?=C1ngel_Gonz=E1lez?=) On 26/02/12 15:57, Anthony Ferrara wrote: > I've gone back and re-read a bunch of the old posts on Type Hinting, > and have come to the conclusion that it won't be done any time soon. > Not because it doesn't have merit, but because there are at least a > few fundamental difficulties that are non-trivial to figure out while > still keeping the usefulness. Can you provide a list? Having clear objectives of what we are intending to fix will help to find a good solution. I suspect that the __cast solution is more complex than needed. And specifically, I forsee having both __castTo() and __castFrom() as a source of conflicts.