Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:56658 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 54298 invoked from network); 28 Nov 2011 20:11:32 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 28 Nov 2011 20:11:32 -0000 Authentication-Results: pb1.pair.com smtp.mail=nikita.ppv@googlemail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=nikita.ppv@googlemail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain googlemail.com designates 209.85.215.42 as permitted sender) X-PHP-List-Original-Sender: nikita.ppv@googlemail.com X-Host-Fingerprint: 209.85.215.42 mail-lpp01m010-f42.google.com Received: from [209.85.215.42] ([209.85.215.42:42442] helo=mail-lpp01m010-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 8D/60-50663-3FAE3DE4 for ; Mon, 28 Nov 2011 15:11:32 -0500 Received: by lami14 with SMTP id i14so718650lam.29 for ; Mon, 28 Nov 2011 12:11:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=0a7vwIKjeea8uEfMvUHWuHr7s6Sd0+ri/grJSJR6TNs=; b=KoF8JMDjXk2fe1pmEwRQNfX7cRgcbdrm24KLrXfj4ZuN/cr2CnDslmuZTRM1BjIUEQ ff1zqibiqg21h4/YmtXoZkxvbTloKgUm60r4K2GqD8X8fNMOpWhOlGgceAf5grMVHgoM bV4opqXh8hs1zUsHrRyGzcECpnkMDw0Y12tGg= MIME-Version: 1.0 Received: by 10.152.130.71 with SMTP id oc7mr29197110lab.25.1322511088485; Mon, 28 Nov 2011 12:11:28 -0800 (PST) Received: by 10.152.26.111 with HTTP; Mon, 28 Nov 2011 12:11:28 -0800 (PST) In-Reply-To: <008601ccae08$9fcff840$df6fe8c0$@alliantinternet.com> References: <008601ccae08$9fcff840$df6fe8c0$@alliantinternet.com> Date: Mon, 28 Nov 2011 21:11:28 +0100 Message-ID: To: Dmitri Snytkine Cc: internals@lists.php.net Content-Type: text/plain; charset=ISO-8859-1 Subject: Re: [PHP-DEV] Any chance of having __invokeStatic() From: nikita.ppv@googlemail.com (Nikita Popov) How would this be different from defining a function MyClass? Nikita On Mon, Nov 28, 2011 at 9:02 PM, Dmitri Snytkine wrote: > I think __invokeStatic() would be a very useful magic function, especially > with support for late static binding. > you could difine it one and all sub-classes will have that option of > basically being callable classes. > > MyClass($params) could then do some processing and return some data. > > This would basically be the same as doing MyClass::doSomething($params); > only without the extra typing of ::doSomething