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

Re: "drop-in replacement" and transpose-words-match



Bart Schaefer wrote on Tue, Jan 19, 2016 at 19:56:08 -0800:
> On Jan 19,  9:28am, Sebastian Gniazdowski wrote:
> } Zsh-syntax-highlighting can be slow, which can be seen by editing ~400
> } lines function with zed -f. Maybe it's because it's doing various
> } things to compensate not that rich information provided by Zsh.
> 
> It's mostly because it's re-analyzing the entire buffer every time any
> change is made, if I recall correctly from the few times I've tried it.

That's basically how it works, but it doesn't explain the slowness on
fned buffers: the initial highlight of an fned buffer involves exactly
one _zsh_highlight call, and yet is slow.

Cheers,

Daniel

P.S. There are two workarounds for the slowness: invoke <edit-command-line>
within fned, or set the undocumented $ZSH_HIGHLIGHT_MAXLENGTH parameter.



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