def func_code(flike):
    """
    Given a function like object (function, static method, etc.), return its
    functional code object. Attempts to bridge the gap between different versions'
    introspective namings.
    """
    if hasattr(flike, 'func_code'):
        return flike.func_code
    elif hasattr(flike, '__code__'):
        return flike.__code__
    else:
        raise ValueError("don't know where to find function's code")
