[linedit-devel] maybe a possible bug?

Nikodemus Siivola nikodemus at random-state.net
Mon Jun 1 17:02:06 UTC 2009


2009/6/1 james morris <james at jwm-art.net>:

> No problem. I'm still wondering though as to why CTRL-left/right/up/down
> cause sbcl/linedit to hang? Sorry, i'm only a humble beginner to common
> lisp so all i can do is report problems :|

No idea, sorry, and I can't even easily reproduce this on my system as
C-arrows are caught by my window manager -- I'll need to reconfigure
it before I can have a look.

Once it hangs, can you get a backtrace? Either by C-c at the terminal,
and typing "ba" <enter> in the debugger (without quotes), or by
attaching GDB: gdb -p <pid of sbcl>, followed by "ba" <enter> (again
without quotes) in gdb, followed by "call backtrace_from_fp($rbp,
100)" (still no quotes)?

Apropos, I hope you are not using Linedit as your _primary_ Lisp
environment? It is definitely something of a fallback: you are going
to be a gazillion times more productive using eg. Slime.

> I've attempted to change the key mappings to use home/end keys for
> bol/eol but came stuck... i know that the keycodes generated for
> home/end etc are a two-code thing, but not sure how to specify it in the
> keys file within linedit - the defcommand using "home" and "end"
> seems to be ignored by these keys which get caught (on my system
> atleast) by the defcommand for "M-O" (IIRC) and the 2nd part of their
> keycodes comes out as 'F' or 'H' (IIRC) at the prompt.

Not sure about the cause at all -- it's been a long while since I had
to figure stuff like that out -- but one thing you can do:

* Trace LINEDIT::READ-CHORD to see what your Home and End keys are
translated into, if anything.

* If they don't get reasonable translations, add the appropriate
translations to terminal-translations.lisp.

The whole way terminal stuff is translated is a bit hacky -- the
proper way would be to try to find the stuff from terminfo db, I
think.

Cheers,

 -- Nikodemus




More information about the linedit-devel mailing list