emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] bug in lisp code blocks


From: Mark Scala
Subject: Re: [O] bug in lisp code blocks
Date: Wed, 30 Jul 2014 10:49:50 -0500

Thanks, Bastien, for helping me report this bug more effectively.
This email summarizes all the information I have about this bug and
how to reproduce it. The problem is that a comment which appears as
the _last_ line of a (common) lisp code block causes an error when
that block is evaluated with C-c C-c. Here's how to reproduce it:

1. You will need to have SBCL and Slime
   installed. Your distribution of linux probably has a good enough
   SBCL (I'm using 1.2.0 in Arch linux). The easiest way to get the
   latest version of Slime is with Quicklisp, which you can find here
   (together with instructions to install):
   http://www.quicklisp.org/beta/.

   Once you have Quicklisp installed and loaded, installing Slime is a
   matter of calling (ql:quickload "swank") at the sbcl repl.

  Note: I am also able to reproduce the bug using clisp:
    -  GNU CLISP 2.49 (2010-07-07) (built on
var-lib-archbuild-extra-x86_64-barthalion)

2. Start emacs with the following as the entire init.el (of course,
   you'll probably have to modify the paths).

#+BEGIN_SRC emacs-lisp

(add-to-list 'load-path (expand-file-name "~/opt/org-mode/lisp"))
                                                            (require
'org)

(org-babel-do-load-languages

  'org-babel-load-languages

      '((lisp . t)))

          (setq inferior-lisp-program "/usr/bin/sbcl")

        (add-to-list 'load-path
"~/quicklisp/dists/quicklisp/software/slime-2.8")
                                  (require 'slime)
#+END_SRC
Note: I've also just reproduced the bug using the version of org-mode
that ships with Emacs 24:

   - Org-mode version 7.9.3f (release_7.9.3f-17-g7524ef @
/usr/share/emacs/24.3/lisp/org/)

3. Finally, create a new org file and insert this block:

#+BEGIN_SRC lisp :results output

(format t "Hello world.")
  ;; comment after, causes crash when block is evaluated with C-c C-c
#+END_SRC

If you now evaluate the block with C-c C-c, you should get an EOF
error. Here is a piece of the debugger report:

#+BEGIN_QUOTE
end of file on #<SB-IMPL::STRING-INPUT-STREAM {1003F862D3}>
   [Condition of type END-OF-FILE]
#+END_QUOTE
It appears that the bug is caused by a comment string that is the last
element of the block. Comments elsewhere do not cause this error.

Here are the versions strings of the software I'm running:

  - GNU Emacs 24.3.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.12.2)
of 2014-06-11 on var-lib-archbuild-staging-x86_64-jgc
  - Org-mode version 8.3beta (release_8.3beta-51-g02f2d5 @
/home/mark/opt/org-mode/lisp/)
  - SBCL 1.2.0

On Tue, Jul 29, 2014 at 9:13 AM, Bastien <address@hidden> wrote:
> Hi Mark,
>
> you forgot to CC the list -- please do so, so that anyone can help
> fixing the problem.
>
> All this new information is important.  A complete recipe would take
> the user from a bare emacs -Q to an emacs with a sbcl connection and
> slime, and explain the steps for launching sbcl, connecting via slime,
> etc.
>
> Assume the ones who may fix the problem (like me and other maintainers)
> are not 100% familiar with Emacs/slime/sbcl, even though they can follow
> good recipes easily.
>
> Thanks for your efforts!
>
> PS: The hint about the last commented line triggered the bug is
> important and will certainly lead to a quick fix.
>
> --
>  Bastien



reply via email to

[Prev in Thread] Current Thread [Next in Thread]