# Path: django_evolution/compat/datastructures.py



    from pickle import _Unpickler as Unpickler
    from pickle import Unpickler
from django_evolution.compat.datastructures import OrderedDict

try:
    # Python 3.x
except ImportError:
    # Python 2.x



class SortedDict(dict):
    """Compatibility for unpickling a SortedDict.

    Old signatures may use an old Django ``SortedDict`` structure, which does
    not exist in modern versions. This changes any construction of this
    data structure into a :py:class:`collections.OrderedDict`.
    """

    def __new__(cls, *args, **kwargs):
        """Construct an instance of the class.

        Args:
            *args (tuple):
                Positional arguments to pass to the constructor.

            **kwargs (dict):
                Keyword arguments to pass to the constructor.

        Returns:
            collections.OrderedDict:
            The new instance.
        """

# Path: django_evolution/compat/datastructures.py



# Path: django_evolution/compat/picklers.py
    from pickle import _Unpickler as Unpickler
    from pickle import Unpickler
from django_evolution.compat.datastructures import OrderedDict


try:
    # Python 3.x
except ImportError:
    # Python 2.x



class SortedDict(dict):
    """Compatibility for unpickling a SortedDict.

    Old signatures may use an old Django ``SortedDict`` structure, which does
    not exist in modern versions. This changes any construction of this
    data structure into a :py:class:`collections.OrderedDict`.
    """

    def __new__(cls, *args, **kwargs):
        """Construct an instance of the class.

        Args:
            *args (tuple):
                Positional arguments to pass to the constructor.

            **kwargs (dict):
                Keyword arguments to pass to the constructor.

        Returns:
            collections.OrderedDict:
            The new instance.
        """

        return OrderedDict.__new__(cls, *args, **kwargs)