@property
    def files(self):
        """Yields archive file information."""
        # try new file header format first, then fallback on old
        for header in (r"(.*)\t\[\[\[1\n", r"^(\d+)\n$"):
            header = re.compile(header)
            filename = None
            self.fd.seek(0)
            line = self.readline()
            while line:
                m = header.match(line)
                if m is not None:
                    filename = m.group(1)
                    try:
                        filelines = int(self.readline().rstrip())
                    except __HOLE__:
                        raise ArchiveError('invalid archive format')
                    filestart = self.fd.tell()
                    yield (filename, filelines, filestart)
                line = self.readline()
            if filename is not None:
                break
dataset/ETHPy150Open radhermit/vimball/vimball/base.py/Vimball.files