On 2020-05-11 09:21, Chris Angelico wrote:
On Mon, May 11, 2020 at 6:09 PM Steve Barnes <gadgetst...@live.co.uk> wrote:

Actually, in the case of the “wrong quotes” it puts the pointer under the 
character before the space character or at the end of the line (if you have a 
fixed spacing font – worse if you don’t) – it still doesn’t tell you which 
character is invalid.


This is actually a good point. Having an invalid character in an
identifier shows the caret at the end of the identifier, regardless of
where in the identifier the error is. That's something that could be
improved on, regardless of the quote issue. There's a new parser on
its way (PEP 617), so it'd be something to consider on that basis.

I wouldn't object if the syntax error reported that, say, the wrong type of quote was being used and included something like: Do you mean "?

Wrong kind of quote (not "). Wrong kind of hyphen or minus (-). Etc.
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/python-ideas@python.org/message/4ORFEYKBYY5J35F5ZZ4ZJSOOD2G6DQ2Y/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to