From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.help Subject: RE: Function pointer Date: Tue, 14 Apr 2009 07:37:50 -0700 Message-ID: <000601c9bd0e$973255e0$0200a8c0@us.oracle.com> References: <43154d5e-b73a-4fd6-b4aa-3bb4027cb409@z9g2000yqi.googlegroups.com> <1ca52c6e-ca27-4ffe-aa95-27b9bbfebe61@z14g2000yqa.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1239719905 16599 80.91.229.12 (14 Apr 2009 14:38:25 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 14 Apr 2009 14:38:25 +0000 (UTC) To: "'Decebal'" , Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Apr 14 16:39:43 2009 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1LtjnH-0002Wn-G8 for geh-help-gnu-emacs@m.gmane.org; Tue, 14 Apr 2009 16:39:23 +0200 Original-Received: from localhost ([127.0.0.1]:50500 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Ltjls-0003Pp-PL for geh-help-gnu-emacs@m.gmane.org; Tue, 14 Apr 2009 10:37:56 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LtjlU-0003M9-34 for help-gnu-emacs@gnu.org; Tue, 14 Apr 2009 10:37:32 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LtjlP-0003BN-EX for help-gnu-emacs@gnu.org; Tue, 14 Apr 2009 10:37:31 -0400 Original-Received: from [199.232.76.173] (port=51161 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LtjlP-0003An-7Y for help-gnu-emacs@gnu.org; Tue, 14 Apr 2009 10:37:27 -0400 Original-Received: from acsinet12.oracle.com ([141.146.126.234]:62882) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1LtjlO-0008Gm-Op for help-gnu-emacs@gnu.org; Tue, 14 Apr 2009 10:37:27 -0400 Original-Received: from rgminet15.oracle.com (rcsinet15.oracle.com [148.87.113.117]) by acsinet12.oracle.com (Switch-3.3.1/Switch-3.3.1) with ESMTP id n3EEanmH032155 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 14 Apr 2009 14:36:51 GMT Original-Received: from acsmt706.oracle.com (acsmt706.oracle.com [141.146.40.84]) by rgminet15.oracle.com (Switch-3.3.1/Switch-3.3.1) with ESMTP id n3EEbPJ0003408; Tue, 14 Apr 2009 14:37:27 GMT Original-Received: from dradamslap1 (/141.144.161.223) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Tue, 14 Apr 2009 14:37:17 +0000 X-Mailer: Microsoft Office Outlook 11 Thread-Index: Acm85eYOMIN7xMUNTPmT2mUp/3hCSgAKDv3w X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3350 In-Reply-To: <1ca52c6e-ca27-4ffe-aa95-27b9bbfebe61@z14g2000yqa.googlegroups.com> X-Source-IP: acsmt706.oracle.com [141.146.40.84] X-Auth-Type: Internal IP X-CT-RefId: str=0001.0A010205.49E49FA0.001C:SCFMA4539814,ss=1,fgs=0 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 1) X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:63729 Archived-At: > > > =A0 =A0 (function) > > > this gives wrong number of arguments. ... > > The very short answer to your question: Use funcall, as in > > =A0 =A0 (funcall function) >=20 > Works likes a charm. Now I have the tools to build the 'little' > functionality I wanted. Thanks. BTW, the reason the error message complained about the wrong number of = args is that `function' is an existing special form - `C-h f function': ,---- | function is a special form in `C source code'. |=20 | (function arg) |=20 | Like `quote', but preferred for objects which are functions. | In byte compilation, `function' causes its argument to be compiled. | `quote' cannot do that. `---- "Function" (special form) `function' expects one argument, and you gave = it zero args.