On 2010-10-07, at 11:31 AM, Aleksandar Matijaca wrote:
Thank you all for the suggestions. Half the battle for the lowly developer is making the development environment comfortable so that one can concentrate on learning and building stuff and not fighting the development environment.
Sent from my iPhone
I just realized I sent my earlier response directly to Aleksandr's email but not to the mailing list.
Short version: Do not rely on a REPL to get back what you typed into it. It's not for that, generally.
A top-level/REPL is a Read-Eval-Print-Loop, not a full IDE. (Some REPL implementations may let you up-arrow or similar to previous expressions. This is a minor convenience, but no substitute for an IDE.)
In modern Lisps, typing a form into a REPL compiles it. The fact that it is available for later use during that session in the REPL does no imply that the original stuff you typed in is around somewhere in the REPL. The function (or other form) is available on the REPL as a compiled object only.
To reliably get, e.g. source for your function doit-3 back, use a full IDE which provides a "source code" editor, one (or several) REPLs, and lots of other stuff. Create your functions and what have you as text files with your IDE's editor - not directly in its running REPL. Compile the forms in the text file on the fly one by one or all at once, etc. usinf the IDE. These forms will be available in the REPL running as part of your IDE (as compiled objects).
Moreover, as if by magic :-) Lisp forms that are stored in Lisp source code files can be made to persist for use another day, even after your REPL has been shut down for the night.
This is not to say that everything gets typed into a source file. You'll key lots of stuff directly into the REPL to test, learn, run an application, etc. Just don't depend on it to do what an IDE is meant to do.
- Dave -