diff options
-rw-r--r-- | linenoise/linenoise.c | 1 | ||||
-rw-r--r-- | txr.1 | 4 |
2 files changed, 5 insertions, 0 deletions
diff --git a/linenoise/linenoise.c b/linenoise/linenoise.c index 57797178..cafa7e0a 100644 --- a/linenoise/linenoise.c +++ b/linenoise/linenoise.c @@ -1848,6 +1848,7 @@ static int edit(lino_t *l, const char *prompt) case BACKSPACE: /* backspace */ case CTL('H'): edit_backspace(l); + paren_jump(l); break; case CTL('D'): /* remove char at right of cursor, or if the line is empty, act as end-of-file. */ @@ -34168,6 +34168,10 @@ character and then returns to the original position a brief moment later. If a new character is typed during the brief time delay, the delay is immediately canceled, so as not to hinder rapid typing. +This back-and-forth jump behavior also occurs when a character is erased using +Backspace, and the the cursor ends up immediately to the right of a +parenthesis. + Note that the matching is unsophisticated; it doesn't observe the lexical conventions and syntax of the \*(TL programming language. For instance, a closing parenthesis outside a string literal may match |