Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: !!$ unitialized at first prompt

On Sep 24,  3:26pm, Peter Stephenson wrote:
} So, without adding additional complexity, doing it on reading in is
} the only sensible place in the other case (what it happens to do at
} that point is a different matter but if you've seen the completion
} system you'll realise interfacing to the lexical analyser just to
} split up words isn't much fun with our current implementation).

The complexity here seems to be that the history is stored as an
array of lines with pointers into each line for the word positions,
so it's not as simple as calling bufferwords() to get the parsed
result and then store all the individual words.

History is doing a complex task, attempting to maintain both the
lexical interpretation and literal text of the history.  In fact it
originally stored both separately -- excerpt from an ancient manual:

`toggle-literal-history (ESC-R ESC-r)'
     Toggle between literal and lexical history.  The default is lexical
     history unless the `HIST_LIT' option is set.

Messages sorted by: Reverse Date, Date, Thread, Author