login  home  contents  what's new  discussion  bug reports     help  links  subscribe  changes  refresh  edit

Testing Lisp under FriCAS Interpreter
fricas
(1) -> )lisp (setq $dalymode t)
Your user access level is compiler and this command is therefore not available. See the )set userlevel command for more information. (+ 2 3)
Cannot find a definition or applicable library operation named 2 with argument type(s) PositiveInteger
Perhaps you should use "@" to indicate the required return type, or "$" to specify which version of the function you need.

The above works exactly the same under Linux with a file containing the two lisp lines and then read in using )read. However, in Linux (but not here), a subsequent (+ 2 3) will evaluate to 5.

\begin{verbatim} file lisptest.input contains two lines: )lisp (setq $dalymode t) (+ 2 3)

(1) -> )read lisptest.input )list (setq $dalymode t)

Value = T (+ 2 3)

Cannot ...

(1)-> (+ 2 3) (1)-> Value = 5 (1)-> \end{verbatim}

fricas
(+ 2 3)
Cannot find a definition or applicable library operation named 2 with argument type(s) PositiveInteger
Perhaps you should use "@" to indicate the required return type, or "$" to specify which version of the function you need.

So it seems Tim's patch to intercept the Interpreter is not "thorough". There are other entry points like )read ... or )lisp (load ...) where lines are fed to the Interpreter without being intercepted.


Some or all expressions may not have rendered properly, because Latex returned the following error:
This is pdfTeX, Version 3.141592653-2.6-1.40.24 (TeX Live 2022/Debian) (preloaded format=latex)
 restricted \write18 enabled.
entering extended mode
 I can't find file `2455191169929986520-16.0px.tex'.
<*> 2455191169929986520-16.0px.tex

(Press Enter to retry, or Control-D to exit) Please type another input file name Emergency stop. <*> 2455191169929986520-16.0px.tex

No pages of output. Transcript written on texput.log.




  Subject:   Be Bold !!
  ( 15 subscribers )  
Please rate this page: