Tal Einat added the comment:

ParenMatch is indeed failing when the cursor is after the first parenthesis of 
the following code:

(3 +
 4 - 1)

This happens both in Shell and Editor windows.

I've traced the problem down to HyperParser. It doesn't properly support 
multi-line statements, as can be seen by the following line in 
HyperParser.__init__():

stopatindex = "%d.end" % lno

(this appears twice, once in each branch of the same if statement)

Fixing this requires looking forward a few lines to find the end of the 
statement. I'm continuing to look through the code to try to find an efficient 
way to do this (without parsing the entire file).

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue21694>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to