def extend(instance, new_class):
instance.__class__ = type(<EOL>'<STR_LIT>' % (instance.__class__.__name__, new_class.__name__),<EOL>(new_class, instance.__class__,),<EOL>{}<EOL>)<EOL>
Adds new_class to the ancestors of instance.

    :param instance: Instance that will have a new ancestor.
    :param new_class: Ancestor.