On Sat, May 16, 2026 at 09:14:15PM +0800, Qian Yun wrote: > If you do something like "sin(x) pretend SExpression", > it will take a long time. > > This is useful during debugging. > > After this patch, the output is still unreadable, but much faster.
I admit that I find Lisp level printouts of some kinds of FriCAS data useless. Basically, this is when types are part of data structure (in particular representation of functions typically contains type). It is not clear to me if speeding up such useless printouts is worthwile. OTOH without '*print-pretty*' even otherwise simple printouts are much harder to read. > - Qian > > diff --git a/src/lisp/primitives.lisp b/src/lisp/primitives.lisp > index 65783b28..379b259d 100644 > --- a/src/lisp/primitives.lisp > +++ b/src/lisp/primitives.lisp > @@ -567,11 +567,12 @@ > (defstruct (SPAD_KERNEL > (:print-function > (lambda (p s k) > + (let ((*print-pretty* nil)) > (format s "#S~S" (list > 'SPAD_KERNEL > :OP (SPAD_KERNEL-OP p) > :ARG (SPAD_KERNEL-ARG p) > - :NEST (SPAD_KERNEL-NEST p)))))) > + :NEST (SPAD_KERNEL-NEST p))))))) > OP ARG NEST (POSIT 0)) > > (defmacro SET_SPAD_KERNEL_POSIT(s p) `(setf (SPAD_KERNEL-POSIT ,s) ,p)) > > -- > You received this message because you are subscribed to the Google Groups > "FriCAS - computer algebra system" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion visit > https://groups.google.com/d/msgid/fricas-devel/cacd1f3e-e5d2-4001-80d4-73667b87d525%40gmail.com. -- Waldek Hebisch -- You received this message because you are subscribed to the Google Groups "FriCAS - computer algebra system" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion visit https://groups.google.com/d/msgid/fricas-devel/aghxQQQUOy1aAnMk%40fricas.org.
