@classmethod
def from_clang_fixit(cls, fixit, file):
    """
        Creates a Diff object from a given clang fixit and the file contents.

        :param fixit: A cindex.Fixit object.
        :param file:  A list of lines in the file to apply the fixit to.
        :return:      The corresponding Diff object.
        """
    assert isinstance(file, (list, tuple))
    oldvalue = '\n'.join(file[fixit.range.start.line - 1:fixit.range.end.line])
    endindex = fixit.range.end.column - len(file[fixit.range.end.line - 1]) - 1
    newvalue = oldvalue[:fixit.range.start.column - 1
        ] + fixit.value + oldvalue[endindex:]
    new_file = file[:fixit.range.start.line - 1] + type(file)(newvalue.
        splitlines(True)) + file[fixit.range.end.line:]
    return cls.from_string_arrays(file, new_file)
