liquidev / lintplus

An improved linting plugin for the lite text editor.
59 stars 7 forks source link

Support for "gutter rails" #3

Closed liquidev closed 3 years ago

liquidev commented 3 years ago

This is a thing that can be seen in Rust error messages:

error[E0382]: use of moved value: `a`
 --> src/main.rs:5:5
  |
2 |     let a = String::from("aa");
  |         - move occurs because `a` has type `String`, which does not implement the `Copy` trait
3 |     let b = a;
  |             - value moved here
4 |     println!("{}", b);
5 |     a
  |     ^ value used here after move

I think it would be fun (and quite useful) to create a visual representation of these errors in the editor.

Basically, a "gutter rail" is a "rail" on the gutter, which is simply a vertical line spanning from the first line where the error occurs, to the last line where the error's children messages end.

liquidev commented 3 years ago

Done.

screenshot 1

screenshot 2