Metadata-Version: 2.0
Name: diff
Version: 0.4.0
Summary: You diff objects, you find out why they ain't the same.
Home-page: https://github.com/Julian/diff
Author: Julian Berman
Author-email: Julian@GrayVines.com
License: UNKNOWN
Platform: UNKNOWN
Classifier: Development Status :: 3 - Alpha
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 2.7
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 2
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Programming Language :: Python :: Implementation :: PyPy
Requires-Dist: attrs
Requires-Dist: zope.interface

====
diff
====

*Diff some stuff, find out why it ain't the same.*


``diff`` defines a difference protocol. Watch:

.. codeblock:: python

    >>> class LonelyObject(object):
    ...     def __diff__(self, other):
    ...         return "{} is not like {}".format(self, other)
    ...
    ...     def __repr__(self):
    ...         return "<LonelyObject>"

    >>> from diff import diff
    >>> diff(LonelyObject(), 12).explain()
    '<LonelyObject> is not like 12'


