Works on must functionlike objects including str, which has no func_name

    Args:
        func (function):

    Returns:
        str:

    CommandLine:
        python -m utool.util_str --exec-get_callable_name

    Example:
        >>> # ENABLE_DOCTEST
        >>> from utool.util_str import *  # NOQA
        >>> func = len
        >>> result = get_callable_name(func)
        >>> print(result)
        len

def get_callable_name(func):
    """ Works on must functionlike objects including str, which has no func_name

    Args:
        func (function):

    Returns:
        str:

    CommandLine:
        python -m utool.util_str --exec-get_callable_name

    Example:
        >>> # ENABLE_DOCTEST
        >>> from utool.util_str import *  # NOQA
        >>> func = len
        >>> result = get_callable_name(func)
        >>> print(result)
        len
    """
    try:
        return meta_util_six.get_funcname(func)
    except AttributeError:
        if isinstance(func, type):
            return repr(func).replace('<type \'', '').replace('\'>', '')
        elif hasattr(func, '__name__'):
            return func.__name__
        else:
            raise NotImplementedError(('cannot get func_name of func=%r'
                                        'type(func)=%r') % (func, type(func)))