Save Ukraine

Note #360

Christian Kruse

In reply to http://nullprogram.com/blog/2017/09/07/

Chris Wellons writes in this article about gap buffers and their performance indications when using multiple-cursors.el. He states that because of the technical implementation of changes in Emacs as gap buffers things like multiple-cursors.el are a performance hit and thus should not be used. Instead one should use search & replace as well as macros.

I totally disagree. Performance is nothing I should be molested with as a user. When I choose to use a tool I look at the mental overhead it adds. Will it disturb my workflow? How much thought do I have to invest to use it properly? How much thought is necessary to solve my editing problems?

Macros, for example, add a lot of mental overhead. I have to be aware of many things: I have to ensure that the cursor is at a defined position before executing it (often done with a movement to the beginning of the line), I have to ensure that cursor movements are reproducible in the different contexts, etc, pp. It totally disturbs me in what I am doing right now.

Search & replace on the other hand add a bit of complexity, but much less than macros. The biggest difference is that I can't see my changes before executing the replace.

This is fixed when using multiple cursors: I instantly see my changes and can adopt them, e.g. in case of typos. Also more complex edits are possible since all cursor movements are done on all cursors.

I just don't care about the performance. Make it fast enough that I don't get annoyed by lag, that's good enough for me.