From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Eric Schulte" Subject: Re: Unable to select source code blocks Date: Sat, 26 Feb 2011 09:05:04 -0700 Message-ID: <874o7qeoph.fsf@gmail.com> References: <218C5BA7-3C6A-46DF-8D59-9C92EF3F3370@me.com> <87aahpzjuy.fsf@ucl.ac.uk> <34FD3967-0A59-4C66-A35D-4171D77E0A07@me.com> <8762sbfca5.fsf@ucl.ac.uk> <87r5avhb46.fsf@gmail.com> <2DD6BE58-EAB5-4335-B579-B48F2D79F705@me.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from [140.186.70.92] (port=48254 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PtNA3-00050P-DE for emacs-orgmode@gnu.org; Sat, 26 Feb 2011 11:38:32 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PtN9x-0003Xj-Uv for emacs-orgmode@gnu.org; Sat, 26 Feb 2011 11:38:27 -0500 Received: from mail-px0-f169.google.com ([209.85.212.169]:40949) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PtN9x-0003Xa-QN for emacs-orgmode@gnu.org; Sat, 26 Feb 2011 11:38:21 -0500 Received: by pxi9 with SMTP id 9so616125pxi.0 for ; Sat, 26 Feb 2011 08:38:20 -0800 (PST) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Giorgio Valoti Cc: emacs-orgmode@gnu.org Giorgio Valoti writes: > Il giorno 26/feb/2011, alle ore 01.08, Eric Schulte ha scritto: > >>>> [=E2=80=A6] >>>=20 >>> The problem doesn=E2=80=99t seem related to the autocomplete system, it= =E2=80=99s the >>> org-babel-src-block-names function that returns an empty list. I don=E2= =80=99t >>> know why, the org-babel-src-name-w-name-regexp used by that function >>> seems ok at a cursory look. >>>=20 >>=20 >> Could you attach a small file with named code blocks which aren't caught >> by this function? I just ran the following in by file of scraps of >> code examples and got 60 names returned >>=20 >> #+begin_src emacs-lisp >> (length (org-babel-src-block-names)) >> #+end_src > > How embarrassing! I used this > > #+begin_src emacs-lisp > (org-babel-src-block-names) > #+end_src > Hm this should work as well... > > which returns nil or so I thought. I was expecting to see the list of > source blocks in the results. > > Using your snippet on the same file: > > #+begin_src emacs-lisp > (length (org-babel-src-block-names)) > #+end_src > > #+results: > : 19 > > However, using eval-last-sexp I get a list with nil items. Is it correct? > That is weird, this should result in the insertion of an Org-mode list containing the names of the named code blocks in your file. #+begin_src emacs-lisp :results list (org-babel-src-block-names) #+end_src If not, then I'm not sure what exactly is being returned by `org-babel-src-block-names' on your system -- it should be a list of strings. You could also try executing the function directly by calling `eval-expression' M-: (org-babel-src-block-names) within the Org-mode buffer. also, make sure you have the latest version of Org-mode. Best -- Eric > > > Ciao > -- > Giorgio Valoti > > > _______________________________________________ > Emacs-orgmode mailing list > Please use `Reply All' to send replies to the list. > Emacs-orgmode@gnu.org > http://lists.gnu.org/mailman/listinfo/emacs-orgmode