3 ms·
Thanks to Microsoft, it is now entrenched in the JavaScript and even the Language Server Protocol. Eventually they should just put UTF-16 on fire, and move to U
by xvilka 7y ago
Thanks to Microsoft, it is now entrenched in the JavaScript and even the Language Server Protocol. Eventually they should just put UTF-16 on fire, and move to UTF-8 as all smart people did already. Microsoft was always who shambles behind progress with the lack of C99 support until recent times, UCS-2, MAX_PATH (MSBuild still doesn't work with long names, in 2019!), and many other similar problems.
- IshKebab 7y agoYes the language server protocol is particularly insane because they use UTF-16 word positions (sort of, it's JavaScript so it's not anything standard really), but the actual text data is sent as UTF-8! So for my sane UTF-8 speaking language server the text gets converted from UTF-8 to UTF-16 when loaded from disk, then converted back for transmission via the LSP, then converted back to UTF-16 by my language server so I can handle the positions, and then it does everything in reverse again on the way back! Absolute madness. I think they will fix it eventually though. The madness is too great to ignore.
- mark-r 7y agoIt's a bit unfair to pick on Microsoft here. They were an early supporter of Unicode, back when UCS-2 looked like the best and/or only way to encode Unicode.