(path)
return d + p + '.cache'
Convert an absolute path to a directory name for use in a cache.

    The algorithm used is:

    #. On Windows, any ``':'`` in the drive is replaced with ``'---'``.
    #. Any occurrence of ``os.sep`` is replaced with ``'--'``.
    #. ``'.cache'`` is appended.
Convert an absolute path to a directory name for use in a cache.
Convert an absolute path to a directory name for use in a cache .
def path_to_cache_dir(path):
    """
    Convert an absolute path to a directory name for use in a cache.

    The algorithm used is:

    #. On Windows, any ``':'`` in the drive is replaced with ``'---'``.
    #. Any occurrence of ``os.sep`` is replaced with ``'--'``.
    #. ``'.cache'`` is appended.
    """
    d, p = os.path.splitdrive(os.path.abspath(path))
    if d:
        d = d.replace(':', '---')
    p = p.replace(os.sep, '--')
    return d + p + '.cache'
def path_to_cache_dir ( path ) : d , p = os . path . splitdrive ( os . path . abspath ( path ) ) if d : d = d . replace ( ':' , '---' ) p = p . replace ( os . sep , '--' ) return d + p + '.cache'