diff options
Diffstat (limited to 'Lib/tabnanny.py')
-rwxr-xr-x | Lib/tabnanny.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Lib/tabnanny.py b/Lib/tabnanny.py index 7d2ca52..2595540 100755 --- a/Lib/tabnanny.py +++ b/Lib/tabnanny.py @@ -196,7 +196,7 @@ class Whitespace: other.indent_level(ts)) ) return a - # Return true iff self.indent_level(t) < other.indent_level(t) + # Return True iff self.indent_level(t) < other.indent_level(t) # for all t >= 1. # The algorithm is due to Vincent Broman. # Easy to prove it's correct. @@ -211,7 +211,7 @@ class Whitespace: # Note that M is of the form (T*)(S*) iff len(M.norm[0]) <= 1. def less(self, other): if self.n >= other.n: - return 0 + return False if self.is_simple and other.is_simple: return self.nt <= other.nt n = max(self.longest_run_of_spaces(), @@ -219,8 +219,8 @@ class Whitespace: # the self.n >= other.n test already did it for ts=1 for ts in range(2, n+1): if self.indent_level(ts) >= other.indent_level(ts): - return 0 - return 1 + return False + return True # return a list of tuples (ts, i1, i2) such that # i1 == self.indent_level(ts) >= other.indent_level(ts) == i2. |