joaotavora / sly

Sylvester the Cat's Common Lisp IDE
1.26k stars 142 forks source link

sly's trace function does not work on Allegro 10.1 #458

Closed rpgoldman closed 3 years ago

rpgoldman commented 3 years ago

For whatever reason, C-c C-t in sly does not successfully trace functions on ACL, although it claims to. To see this, use it to trace some arbitrary function and then type (trace) at the REPL. You will see that no functions are reported as being traced.

I am not sure whether the invocation of trace is done wrong or skipped, or whether this is a threading issue, so that the tracing is in some incorrect thread.

I am willing to dig into fixing this, but need some help figuring out where to start.

P.S. what does it mean to be "traced for trace dialog"? I don't know what "trace dialog" is, so this is a little confusing.

joaotavora commented 3 years ago

The default behaviour for C-c C-t is to trace for the "trace dialog", meaning SLY's trace dialog, which you can reach with C-c T (capital T) and read about in the manual (https://joaotavora.github.io/sly/#Trace-Dialog).

In contrast, C-c M-t is the boring old Lisp trace, :wink: If you're using Allegro with a GUI (I was for many years), you'll notice those traces show up in ACL's trace dialog.

You can find out the bindings for C-c C-t which C-h k and switch between them. I.e. make C-c C-t make boring old lisp trace s instead of SLY-specific ones.

rpgoldman commented 3 years ago

A quick follow-up note: the binding for standard lisp tracing (C-M-t) seems to be clobbered by a standard key binding, transpose-sexps. Maybe it would be good to add a keymap for sly tracing to avoid such collisions? So we would have C-c t as the prefix for a new keymap? C-c t t for sly trace for trace dialog and C-c t T for BOLT (boring old lisp trace ;-) )

joaotavora commented 3 years ago

Note that C-M-t is not the same as C-c M-t. The latter involves typing C-c then letting go of the control key, and then typing M-t

joaotavora commented 3 years ago

So we would have C-c t

Not a bad idea, but I personally have C-c T and C-c C-t hardwired in my brain. It's fine to add more bindinds and C-c t seems to be unused, indeed, but I wonder if there are lots of things to put there...

rpgoldman commented 3 years ago

Note that C-M-t is not the same as C-c M-t. The latter involves typing C-c then letting go of the control key, and then typing M-t

Got it! Thanks! That clears things up for me. I had misread the keybinding hint in the menu!