#NEWLINE# def unify_object( u , v , s ) : #NEWLINE# #INDENT# ' Unify two Python objects\n\n    Unifies their type and ``__dict__`` attributes\n\n    >>> from logpy.unifymore import unify_object\n    >>> from logpy import var\n    >>> class Foo(object):\n    ...     def __init__(self, a, b):\n    ...         self.a = a\n    ...         self.b = b\n    ...     def __str__(self):\n    ...         return "Foo(%s, %s)"%(str(self.a), str(self.b))\n\n    >>> x = var(\'x\')\n    >>> f = Foo(1, x)\n    >>> g = Foo(1, 2)\n    >>> unify_object(f, g, {})\n    {~x: 2}\n    ' #NEWLINE# if ( type ( u ) != type ( u ) ) : #NEWLINE# #INDENT# return False #NEWLINE# #UNINDENT# return unify ( u . __dict__ , v . __dict__ , s )