# AUTOGENERATED! DO NOT EDIT! File to edit: ../nbs/32_pyty.ipynb.

# %% auto 0
__all__ = ['ismethodwrapper', 'ismthdwrap', 'isbuiltinfunctiontype', 'isbuiltin']

# %% ../nbs/32_pyty.ipynb 4
from types import MethodWrapperType, BuiltinFunctionType
from typing import TypeGuard

# %% ../nbs/32_pyty.ipynb 6
def ismethodwrapper(x) -> TypeGuard[MethodWrapperType]:
    '''Check if x is of type `MethodWrapperType`.
    
    See Also
    --------
    ismthdwrap: alias for `ismethodwrapper`    
    '''
    return isinstance(x, MethodWrapperType)


def ismthdwrap(x) -> TypeGuard[MethodWrapperType]:
    '''Check if x is of type `MethodWrapperType`.
    
    See Also
    --------
    ismethodwrapper: alias for `ismethismthdwrapodwrapper`    
    '''
    return ismethodwrapper(x)

def isbuiltinfunctiontype(x) -> TypeGuard[BuiltinFunctionType]:
    '''Check if x is of type `BuiltinFunctionType`.
    
    See Also
    --------
    isbuiltin: alias for `isbuiltinfunctiontype`    
    '''
    return isinstance(x, BuiltinFunctionType)

def isbuiltin(x) -> TypeGuard[BuiltinFunctionType]:
    '''Check if x is of type `BuiltinFunctionType`.
    
    See Also
    --------
    isbuiltinfunctiontype: alias for `isbuiltin`    
    '''
    return isbuiltinfunctiontype(x)
