Hello,
I have just checked with SBCL, and here is where the error with *READ-DEFAULT-FLOAT-FORMAT* occurs, probably because of threads. Also, your modifications of slime-start-and-load do not work with SBCL. I.e. after doing
(slime-start-and-load (concat *femlisp-root* "start.lisp") "FL.APPLICATION")
I get
... CL-USER> CL-USER> *READ-DEFAULT-FLOAT-FORMAT* SINGLE-FLOAT
When I then set the default format manually in the REPL, it is reset by `M-x slime'.
CL-USER> (setq *READ-DEFAULT-FLOAT-FORMAT* 'DOUBLE-FLOAT) DOUBLE-FLOAT CL-USER> *READ-DEFAULT-FLOAT-FORMAT* DOUBLE-FLOAT CL-USER> [ I have executed `M-x slime' here] CL-USER> *READ-DEFAULT-FLOAT-FORMAT* SINGLE-FLOAT CL-USER>
Yours, Nicolas.
Helmut Eller e9626484@stud3.tuwien.ac.at writes:
Nicolas Neuss Nicolas.Neuss@iwr.uni-heidelberg.de writes:
If Slime is not already running, the load command is not executed.
If Slime is already running, Femlisp is loaded, but the package is not
set.
Can someone tell me how I can achieve my goal?
Yes, this is bit more difficult because most of the commands work asynchronously. I changed slime-start-and-load a bit so that it should be usable for your needs.
In general If you need commands of this sort, it's usually the easiest to write a small CL function for the job, so that Emacs can make a single RPC and doesn't need so much synchronization.
PS: Another problem is that executing (slime) apparently sets back some variables, e.g. *READ-DEFAULT-FLOAT-FORMAT* which I have set to DOUBLE-FLOAT when loading Femlisp. Why is that?
Can't help you here without more details. Which Lisp are you using? Which communication style? Are threads involved? We don't set *READ-DEFAULT-FLOAT-FORMAT* explicit, but there's always the possibility for bug and that we used WITH-STANDARD-IO-SYNTAX in a wrong place.
Helmut.