Skip to content
Snippets Groups Projects
Commit 0aeaca0e authored by Francois-Rene Rideau's avatar Francois-Rene Rideau
Browse files

Only decide at runtime whether to push :asdf-unicode to *features*.

This sometimes allows sharing of fasls between unicode and non-unicode compiler.
Hat tip: Dave Cooper, testing on Allegro.
parent d20ea551
No related branches found
No related tags found
No related merge requests found
...@@ -32,10 +32,14 @@ ...@@ -32,10 +32,14 @@
;;;; Early meta-level tweaks ;;;; Early meta-level tweaks
#+(or abcl (and allegro ics) (and (or clisp cmu ecl mkcl) unicode) #+(or abcl allegro clisp cmu ecl mkcl clozure lispworks sbcl scl)
clozure lispworks (and sbcl sb-unicode) scl)
(eval-when (:load-toplevel :compile-toplevel :execute) (eval-when (:load-toplevel :compile-toplevel :execute)
(pushnew :asdf-unicode *features*)) ;; Check for unicode at runtime, so that a hypothetical FASL compiled with unicode
;; but loaded in a non-unicode setting (e.g. on Allegro) won't tell a lie.
(when (and #+allegro (member :ics *features*)
#+(or clisp cmu ecl mkcl) (member :unicode *features*)
#+sbcl (member :sb-unicode *features*))
(pushnew :asdf-unicode *features*)))
#+allegro #+allegro
(eval-when (:load-toplevel :compile-toplevel :execute) (eval-when (:load-toplevel :compile-toplevel :execute)
......
...@@ -93,9 +93,9 @@ reading emacs-style -*- coding: utf-8 -*- specifications, ...@@ -93,9 +93,9 @@ reading emacs-style -*- coding: utf-8 -*- specifications,
and falling back to utf-8 or latin1 if nothing is specified.") and falling back to utf-8 or latin1 if nothing is specified.")
(defparameter *utf-8-external-format* (defparameter *utf-8-external-format*
#+(and asdf-unicode (not clisp)) :utf-8 (if (featurep :asdf-unicode)
#+(and asdf-unicode clisp) charset:utf-8 (or #+clisp charset:utf-8 :utf-8)
#-asdf-unicode :default :default)
"Default :external-format argument to pass to CL:OPEN and also "Default :external-format argument to pass to CL:OPEN and also
CL:LOAD or CL:COMPILE-FILE to best process a UTF-8 encoded file. CL:LOAD or CL:COMPILE-FILE to best process a UTF-8 encoded file.
On modern implementations, this will decode UTF-8 code points as CL characters. On modern implementations, this will decode UTF-8 code points as CL characters.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment