Edgewall Software

Ticket #399: select-tail-fix-r1135.diff

File select-tail-fix-r1135.diff, 941 bytes (added by hodgestar, 13 years ago)

Fix selected tail.

  • genshi/template/markup.py

     
    308308        """
    309309        match_templates = ctxt._match_templates
    310310
    311         tail = []
    312         def _strip(stream, append=tail.append):
     311        def _strip(stream, append):
    313312            depth = 1
    314313            next = stream.next
    315314            while 1:
     
    353352                    pre_end = idx + 1
    354353                    if 'match_once' not in hints and 'not_recursive' in hints:
    355354                        pre_end -= 1
    356                     inner = _strip(stream)
     355                    tail = []
     356                    inner = _strip(stream, tail.append)
    357357                    if pre_end > 0:
    358358                        inner = self._match(inner, ctxt, start=start,
    359359                                            end=pre_end, **vars)