1.1 --- a/iixr/phrases.py Sat Nov 20 00:00:01 2010 +0100
1.2 +++ b/iixr/phrases.py Sat Nov 20 00:01:14 2010 +0100
1.3 @@ -4,7 +4,7 @@
1.4 Phrase iterators providing navigation over common positions for a number of
1.5 different terms.
1.6
1.7 -Copyright (C) 2009 Paul Boddie <paul@boddie.org.uk>
1.8 +Copyright (C) 2009, 2010 Paul Boddie <paul@boddie.org.uk>
1.9
1.10 This program is free software; you can redistribute it and/or modify it under
1.11 the terms of the GNU General Public License as published by the Free Software
1.12 @@ -168,6 +168,8 @@
1.13 raise StopIteration
1.14
1.15 def is_phrase_position(self, last, last_token, current, current_token):
1.16 - return current - last <= 1 and current_token > last_token
1.17 + last_position, last_preceding = last
1.18 + position, preceding = current
1.19 + return position - last_position <= 1 and current_token > last_token
1.20
1.21 # vim: tabstop=4 expandtab shiftwidth=4