-
Notifications
You must be signed in to change notification settings - Fork 3.5k
Description
Elixir and Erlang/OTP versions
Erlang/OTP 27 [erts-15.1.2] [source] [64-bit] [smp:12:12] [ds:12:12:10] [async-threads:1] [jit]
Elixir 1.17.3 (compiled with Erlang/OTP 27)
Operating system
macOS 14.7.4
Current behavior
This is an issue I previously reported to ElixirLS repo (Issue#451) but was advised to move here.
When using VSCode with the ElixirLS extension version 0.26.4, there is a distracting behavior of syntax error highlighting. On pretty much any non-matching do..end block the whole module gets highlighted with squiggles which is quite distracting. As during editing it is not rare to have non-matching do..end blocks, this happens a lot.
As far as I can recall, this is not a very old behavior, and on a previous Elixir or ElixirLS version the whole-module highlighting didn't happen, although I can't tell on which, maybe around Elixir 1.14.
As I understand, the ability of IDE tooling (ElixirLS in particular) to highlight the errors location with better precision is limited by the amount of information Elixir tokenizer / parser / compiler makes available.
Please refer to the linked ElixirLS issue for screenshots and other details, as I'm not certain where this issue should belong in the end.
Expected behavior
In case of a non-matching block delimiters only have the opening one of the deepest affected block selected, and not the whole block, and of course not anything outside.