Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:62967 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 87453 invoked from network); 13 Sep 2012 08:34:28 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 13 Sep 2012 08:34:28 -0000 Authentication-Results: pb1.pair.com header.from=simon@simon.geek.nz; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=simon@simon.geek.nz; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain simon.geek.nz designates 103.6.213.4 as permitted sender) X-PHP-List-Original-Sender: simon@simon.geek.nz X-Host-Fingerprint: 103.6.213.4 unknown Received: from [103.6.213.4] ([103.6.213.4:60972] helo=simon.geek.nz) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 6E/F6-34511-39A91505 for ; Thu, 13 Sep 2012 04:34:28 -0400 Received: from yogurt.fritz.box (office.pocketrent.com [203.86.207.220]) by simon.geek.nz (Postfix) with ESMTPSA id F03BE608A1; Thu, 13 Sep 2012 20:34:22 +1200 (NZST) Content-Type: text/plain; charset=windows-1252 Mime-Version: 1.0 (Mac OS X Mail 6.0 \(1486\)) In-Reply-To: <553F2A43-1A28-4AB5-9D6F-6B5ADFC420DB@strojny.net> Date: Thu, 13 Sep 2012 20:34:22 +1200 Cc: internals Content-Transfer-Encoding: quoted-printable Message-ID: References: <504F4D33.4070306@ralphschindler.com> <5051968E.7030908@zend.com> <553F2A43-1A28-4AB5-9D6F-6B5ADFC420DB@strojny.net> To: Lars Strojny X-Mailer: Apple Mail (2.1486) Subject: Re: [PHP-DEV] [VOTE] ::class feature to resolve namespaced class names to scalars From: simon@simon.geek.nz (Simon J Welsh) On 13/09/2012, at 8:28 PM, Lars Strojny wrote: > Hi Dmitry, >=20 > Am 13.09.2012 um 10:17 schrieb Dmitry Stogov : > [...] >> I think the syntax is wired. >> Instead of classname::class I would prefer something like = class(classname). >=20 > Wouldn=92t this look too much like a function with all the = implications that might cause like users expecting class($variable) to = work or even class(otherfunc())? >=20 > cu, > Lars I would expect $variable::class to work (like late static bindings). = However, I do agree that class(ClassName) just looks off and makes it = look like you can pass class names to functions. --- Simon Welsh Admin of http://simon.geek.nz/