Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 238796 | Differences between
and this patch

Collapse All | Expand All

(-)py/lekatnet/tpg.py (-3 / +3 lines)
Lines 748-755 Link Here
748
                   item.start is the token from which the extraction starts
748
                   item.start is the token from which the extraction starts
749
                   item.stop is the token where the extraction stops
749
                   item.stop is the token where the extraction stops
750
        """
750
        """
751
        start = item.start and item.start.next_start or 0
751
        start = item.start
752
        stop = item.stop and item.stop.stop or -1
752
        stop = item.stop
753
        return self.input[start:stop]
753
        return self.input[start:stop]
754
754
755
class Token:
755
class Token:
Lines 983-989 Link Here
983
            start : token object as returned by mark
983
            start : token object as returned by mark
984
            stop  : token object as returned by mark
984
            stop  : token object as returned by mark
985
        """
985
        """
986
        return self.lexer[start:stop]
986
        return self.lexer[start.start+1:stop.prev_stop+1]
987
987
988
    def check(self, cond):
988
    def check(self, cond):
989
        """ check a condition and backtrack when it is False
989
        """ check a condition and backtrack when it is False

Return to bug 238796