From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Mikhail Titov" Subject: Re: [babel] Why #+name: is not a member of params? Date: Tue, 5 Jun 2012 19:53:50 -0500 Message-ID: <006301cd437e$d7405430$85c0fc90$@us> References: <006001cd437a$03917d70$0ab47850$@us> <87txypqnip.fsf@gmx.com> Mime-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([208.118.235.92]:46251) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Sc4ZK-00086j-4r for emacs-orgmode@gnu.org; Tue, 05 Jun 2012 21:01:33 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Sc4VU-0004tk-Sd for emacs-orgmode@gnu.org; Tue, 05 Jun 2012 20:57:49 -0400 Received: from mailout-us.gmx.com ([74.208.5.67]:47127) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1Sc4VU-0004tc-LG for emacs-orgmode@gnu.org; Tue, 05 Jun 2012 20:53:52 -0400 In-Reply-To: <87txypqnip.fsf@gmx.com> Content-Language: en-us 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: 'Eric Schulte' Cc: emacs-orgmode@gnu.org > -----Original Message----- > From: Eric Schulte [mailto:eric.schulte@gmx.com] > Sent: Tuesday, June 05, 2012 7:42 PM > To: Mikhail Titov > Cc: emacs-orgmode@gnu.org > Subject: Re: [O] [babel] Why #+name: is not a member of params? >=20 > "Mikhail Titov" writes: >=20 > > Hello! > > > > I=E2=80=99d like to insert a comment into tangle output with a block = name. I thought > I could easily access it (like from org-babel-expand-body:XXX = function) with > > > > (cdr (assq :name params)) > > > ... >=20 > The code block name is not a member of params. Params only holds = header > arguments, not other meta data like the name. The code block name is > stored in the `info' list which is active while the code block is = being > processed, so you could access it with something like the following, > although which is relying on an implementation detail that is not part > of the formal spec (i.e., cheating) and could change. >=20 > #+name: foo > #+begin_src emacs-lisp > (nth 4 info) > #+end_src >=20 > #+RESULTS: foo > : foo Thank you, Eric! Marvelous! It does what I want. I see its definition in ob.el . M.=20