Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:53214 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 79505 invoked from network); 8 Jun 2011 14:42:45 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 8 Jun 2011 14:42:45 -0000 Authentication-Results: pb1.pair.com header.from=martinscotta@gmail.com; sender-id=pass; domainkeys=bad Authentication-Results: pb1.pair.com smtp.mail=martinscotta@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.212.42 as permitted sender) DomainKey-Status: bad X-DomainKeys: Ecelerity dk_validate implementing draft-delany-domainkeys-base-01 X-PHP-List-Original-Sender: martinscotta@gmail.com X-Host-Fingerprint: 209.85.212.42 mail-vw0-f42.google.com Received: from [209.85.212.42] ([209.85.212.42:60772] helo=mail-vw0-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 1D/14-48516-46A8FED4 for ; Wed, 08 Jun 2011 10:42:45 -0400 Received: by vwl1 with SMTP id 1so444365vwl.29 for ; Wed, 08 Jun 2011 07:42:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=bQ6mMHyN/Fc3+IF0jg80bSgHDL2aCzuNB/7s+S0lM4g=; b=VCS5RwmjPEFo9KrmdncfDVMwmxyBxi9NMO3FcrWAF0RoRdK8OeLm18TtRHWW4U76Mp 1b2ZWc7VJMFOUEluVbDzHSR+ZoQYaTD8Cup7tQyf5/PQoEhYADh7+liX0D79MjQ4BXdj i9A5Cln2TmqTZ8GsPszBxKaj0IldsRzdjEMk0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=sBMuA0cIO+zGjmxbGPvYKB7wVe62ZZTSgKgg+MYKNirFWAywf7a87RAqWs2BO4IURA 9VPmcbIitkgXJZtdM83mJr3uO3qY3YvOSkWo5/XrYOkRTITTdiVC9l0n0YH+2yxeAv3N mRg1aLw1gaifmSDqnDPJjtRWusnF5hxRm2fFY= MIME-Version: 1.0 Received: by 10.220.189.131 with SMTP id de3mr1824222vcb.48.1307544161516; Wed, 08 Jun 2011 07:42:41 -0700 (PDT) Received: by 10.220.192.129 with HTTP; Wed, 8 Jun 2011 07:42:41 -0700 (PDT) In-Reply-To: References: <4DED3D5B.6030307@oracle.com> <4DEE782E.1020605@sugarcrm.com> <7104F8AD-489E-4824-97AA-D9831FAB77AA@bitextender.com> <4DEE8ABB.8040503@sugarcrm.com> <7E4C6CB6-ED93-4BFC-87B8-94FDEF243896@bitextender.com> <17.29.50253.ACD8EED4@pb1.pair.com> <41.0E.50253.11B9EED4@pb1.pair.com> Date: Wed, 8 Jun 2011 11:42:41 -0300 Message-ID: To: Alexey Shein Cc: Hannes Magnusson , "Matthew Weier O'Phinney" , internals@lists.php.net Content-Type: multipart/alternative; boundary=90e6ba53aa1c467d8804a534596f Subject: Re: [PHP-DEV] Callable type From: martinscotta@gmail.com (Martin Scotta) --90e6ba53aa1c467d8804a534596f Content-Type: text/plain; charset=ISO-8859-1 Martin Scotta On Wed, Jun 8, 2011 at 5:47 AM, Alexey Shein wrote: > 2011/6/8 Hannes Magnusson : > > We have the situation in the docs that parameters declared as arrays > > do not follow the typehinting rules, but parameters as class names do. > > Re-using the callback from the docs could get confusing when > > extensions start to typehint on it, but not the core.. > > > > I think there is a subtle difference between a callback, and a callable. > > In javascript for example, callback is something that is executed on > > certain events "onsuccess" is the typical example. > > There is nothing that says the callable parameter gets executed as a > > part of an event, and I think the default usecase would be to execute > > it right away (f.e. filtering data). > > > > I think I would prefer callable, but I could live with either. > > > > Wikipedia defines callback as "a reference to executable code, or a > piece of executable code, that is passed as an argument to other > code". So there's no "event" meaning put by default, it's just very > often seen callback's usage in javascript. > I just like "callback" term more :) > so 'strpos' is not a reference nor a piece of executable code, it's just the name of a function, which is callable, although we can argue if the function name could be seen as a reference to the code > > > -- > Regards, > Shein Alexey > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > > --90e6ba53aa1c467d8804a534596f--