4 ms·
> More “modern” editors are more ad hoc, no different from modern languages that had simply one implementation rather than a spec — what’s in the implementatio
by square_usual 3y ago
> More “modern” editors are more ad hoc, no different from modern languages that had simply one implementation rather than a spec — what’s in the implementation is by definition what the language is, just as with the old kilogram.
I don't understand what you mean by this. In what way is, e.g. VS Code, "more ad hoc" than vim when it comes to the definition of what a word or a line is?
- zogrodea 3y agoI can't speak about what the person you replied to intended, but there are a few things that come to mind. One is Unicode grapheme clusters (UAX29/the segmentation rules specifically) which browsers are expected to follow. Those rules specify things like how ctrl-right should work and, since the Unicode specifications have multiple versions and will likely have more in the future, I can understand someone who wants the program they use for text-editing to have a more stable definition of a "word" which is probably simpler to work with as it doesn't need to deal with cursor behaviour of different languages/emojis. The second thing I thought of is to do with differences on different operating systems. Windows and macOS have slightly different text-editing behaviours which I can imagine might be annoying. For example, if you have the text "asdf fdsa qwerty" and press ctrl-left/ctrl-right a few times, you'll see that macOS will move your text caret to start/end of the word while Windows will jump over spaces to skip to the next word. I don't think the second point defines other editors as being "more ad hoc" and the first point is just there because VS Code uses Electron and probably inherits the browser's Unicode-compliant behaviour (I have no idea what Intellij and other IDEs do) but I would likely have an easier time remembering the simpler and more platform-consistent definition that Vim has and appreciating that about it for such a specialised tool.