Search code examples
common-lispquicklispasdf

Cannot install lparallel alongside CL21 (?) Failing with CL21.CORE.FUNCTION


I have a weird mix of errors.

I was using CL21, I was in my package, and I wanted to install lparallel. Not possible:

(ql:quickload :lparallel)
To load "lparallel":
  Load 1 ASDF system:
    lparallel
; Loading "lparallel"
; 
; caught ERROR:
;   DYNAMIC-EXTENT on a weird thing: (CL21.CORE.FUNCTION:FUNCTION #:BODY-FN1)
; 
; compilation unit aborted
;   caught 2 fatal ERROR conditions
;   caught 1 ERROR condition
; Evaluation aborted on #<UIOP/LISP-BUILD:COMPILE-FILE-ERROR {1008956C13}>.

I can reproduce it in a new session but it's a bit weird: if I quickload lparallel in cl-user, it complains on not finding the symbol CL21.CORE.FUNCTION, even if I didn't do nothing with CL21 yet:

The name "CL21.CORE.FUNCTION" does not designate any package.

So I ql:quickload CL21 and then on retrying to load lparallel. I get the first error.

But, I tried in Portacle for a fresh image and… I couldn't reproduce this.

Any idea ? Is that an issue with cl21, lparallel, quicklisp or asdf??


Solution

  • cl21 seems to replace the standard reader macro #' with its own version that isn't compatible with lparallel. When you tried to load lparallel in a fresh image, ASDF will load it from the .fasl-files that were compiled with cl21 loaded, so you must either delete those files or force recompilation with

    (asdf:operate 'asdf:load-op :lparallel :force t)
    

    Loading cl21 after lparallel is compiled with the standard language shouldn't cause the same problem.