From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thorsten Jolitz Subject: Re: What does the _ in `(defun org-element-section-parser (_) ...)' stands for? Date: Wed, 10 Feb 2016 21:13:04 +0100 Message-ID: <87r3gkgw8f.fsf@gmail.com> References: <87vb5xsrqa.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:41994) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aTb8W-00035J-Ga for emacs-orgmode@gnu.org; Wed, 10 Feb 2016 15:13:17 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aTb8T-0001Pq-2Y for emacs-orgmode@gnu.org; Wed, 10 Feb 2016 15:13:16 -0500 Received: from plane.gmane.org ([80.91.229.3]:44216) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aTb8S-0001PD-S5 for emacs-orgmode@gnu.org; Wed, 10 Feb 2016 15:13:13 -0500 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1aTb8R-00024k-DP for emacs-orgmode@gnu.org; Wed, 10 Feb 2016 21:13:11 +0100 Received: from f050238071.adsl.alicedsl.de ([78.50.238.71]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 10 Feb 2016 21:13:11 +0100 Received: from tjolitz by f050238071.adsl.alicedsl.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 10 Feb 2016 21:13:11 +0100 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org John Kitchin writes: > I guess it is a required signature for the function (i.e. some other > function will call it with some argument), and _ indicates it is not > used in the body. If you were to give it the arg a name, then checkdoc > would complain about it not being in the docstring. Sounds reasonable, thanks for the explanation. But it does not seem to be a true guess, I tried it out with: #+BEGIN_SRC emacs-lisp (defun my-foo (_) "Hello World. Argument _ unknown argument." (+ 1 1)) #+END_SRC and checkdoc asked me to add the "Argument ..." part for "_" to the docstring. I don't remember that I've seen this before, so maybe this is a rather new feature/convention? > Thorsten Jolitz writes: > >> Hi List, >> just out of curiosity, a few functions in org-element.el contain _ in >> their parameter list, but its not used in the body. >> What does it stand for? > > > -- > Professor John Kitchin > Doherty Hall A207F > Department of Chemical Engineering > Carnegie Mellon University > Pittsburgh, PA 15213 > 412-268-7803 > @johnkitchin > http://kitchingroup.cheme.cmu.edu > > -- cheers, Thorsten