'A microparser that just returns the next tag from the line.'

def tag(self):

    subject = self.subject
    i = self.pointer
    if (i >= len(subject)):
        raise TemplateSyntaxError((u'expected    another    tag,    found    end    of    string:    %s' % subject))
    p = i
    while ((i < len(subject)) and (subject[i] not in (u'    ', u' DCTB '))):
        i += 1
    s = subject[p:i]
    while ((i < len(subject)) and (subject[i] in (u'    ', u' DCTB '))):
        i += 1
    self.backout.append(self.pointer)
    self.pointer = i
    return s
