cl-store maintainers added some support for ABCL, so currently it can store
most standard stuff except structs and classes.
however, storing double-float causes an error caused by ABCL's compiler,
looks like something with types.. interpeted code works quite well.
CL-USER(3): (cl-store:store 1.0d0 "dd.store")
Debugger invoked on condition of type ERROR:
Caught java.lang.ClassCastException: org.armedbear.lisp.Bignum.
i suspect it's following code causes problems (although i didn't dig
(deftype sb32 ()
(defstore-cl-store (obj integer stream)
(declare (optimize speed (safety 1) (debug 0)))
(if (typep obj 'sb32)
(store-32-bit-integer obj stream)
(store-arbitrary-integer obj stream)))
(defun store-32-bit (obj stream)
"Write OBJ down STREAM as a 32 bit integer."
(declare (optimize speed (debug 0) (safety 0))
(type sb32 obj))
(let ((obj (logand #XFFFFFFFF obj)))
(write-byte (ldb (byte 8 0) obj) stream)
(write-byte (ldb (byte 8 8) obj) stream)
(write-byte (ldb (byte 8 16) obj) stream)
(write-byte (+ 0 (ldb (byte 8 24) obj)) stream)))
and, by the way, cl-store works very slow.. possibly that's generic function
invocations, but maybe something can be optimized?
With best regards, Alex Mizrahi.