def overwrite(self, msg, lineno, allowEmpty):
        """ insert into current position in buffer"""
        if not msg and allowEmpty == False:
            return

        if isinstance(msg, list):
            to_write = msg
        else:
            to_write = str(msg).split('\n')
        last_line = len(self._buffer)

        lstart = lineno - 1
        lend = lstart + len(to_write)
        self._buffer[lstart:lend] = to_write

        return (lstart, lend)
dataset/ETHPy150Open joonty/vim-do/autoload/python/buffer.py/HiddenBuffer.overwrite/original