ci_edit icon indicating copy to clipboard operation
ci_edit copied to clipboard

Is there a way to highlight the line in case of a syntax error?

Open gennad opened this issue 5 years ago • 1 comments

I am thinking of the C-e check function that would try to compile the code and highlight the errors in the code if there are any.

gennad avatar Apr 16 '19 00:04 gennad

Nope, but I'd like that.

This is another case where I'd like to consider a new-ish UI/UX.

For example, wdyt of having annotation in the document. So for a file like this

  1 impor os
  2 
  3 def cat():
  4    return "meow"

An annotation would be added after line 1 and before line 2, explaining the error.

  1 impor os
SyntaxError: invalid syntax
  2 
  3 def cat():
  4    return "meow"

The text SyntaxError: invalid syntax wouldn't really be part of the document. The cursor would skip it when going up and down (a cursor on line 1 would jump to line 2 when down arrow was pressed).

dschuyler avatar Apr 16 '19 02:04 dschuyler