commit 4904874a453f0bf01b0fd502384e06f1e430790d parent bfe546196b2573fcc725db00a61c8613ed7b5964 Author: Antoine Amarilli <a3nm@a3nm.net> Date: Sat, 8 Dec 2012 22:35:18 +0100 fix bug disabling rhyme check when disabling classical rules Diffstat:
rhyme.py | | | 5 | +++-- |
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/rhyme.py b/rhyme.py @@ -104,8 +104,9 @@ class Rhyme: return self.restrict(Rhyme(line, constraint, self.mergers)) def satisfied(self): - return (len(self.eye) >= self.constraint.eye - and len(self.phon) > 0 or not self.constraint.classical) + return (len(self.phon) >= self.constraint.phon + and len(self.eye) >= self.constraint.eye + and (len(self.eye) > 0 or not self.constraint.classical)) def pprint(self): pprint(self.phon)