fixes issue113 - assertion represenation issue

--HG--
branch : trunk
This commit is contained in:
holger krekel
2010-07-29 12:55:39 +02:00
parent 92bfb58798
commit efeae72509
4 changed files with 26 additions and 9 deletions

View File

@@ -125,16 +125,13 @@ class Source(object):
try:
compile_command(trysource)
except (SyntaxError, OverflowError, ValueError):
pass
else:
break # got a valid or incomplete statement
# 2. find the end of the statement
for end in range(lineno+1, len(self)+1):
trysource = self[start:end]
if trysource.isparseable():
break
continue
# 2. find the end of the statement
for end in range(lineno+1, len(self)+1):
trysource = self[start:end]
if trysource.isparseable():
return start, end
return start, end
def getblockend(self, lineno):