I have tried this on both, Win32 and Mac OS X newLISP-tk and cannot see the problem newbert is seeing loading this code from the newLISP-tk frontend or executing the second statement interactively
Sorry, for my (poor) english. I'll try to sum up more clearly ;)
Here is the code :
(set 'n (eval-string (read-line)))
- Interactively, it works right on both console
newlisp and
newlisp-tk :
newLISP v.8.8.9 on Win32 MinGW.
> (set 'n (eval-string (read-line)))
55
55
> n
55
>
I put the code in a script file named
test.lsp, for instance. I launch the
newlisp-tk console and I load the script into it (Menu
File/Load ...) :
- In this way, it still works right but I must type <Enter> twice :
newLISP v.8.8.9 on Win32 MinGW.
> 55
> n
55
>
- Now if I launch the script file (
test.lsp) in
newlisp-tk with the help of a
batch file or with the very usefull
run.exe or from a text editor :
newLISP v.8.8.9 on Win32 MinGW.
> 55
55
> n
nil
>
- If I launch the script in
newlisp by double-clicking on the file, there is no problem :
55
newLISP v.8.8.9 on Win32 MinGW, execute 'newlisp -h' for more info.
> n
55
>