AlkantarClanX12

Your IP : 18.227.49.73


Current Path : /usr/lib64/python3.6/__pycache__/
Upload File :
Current File : //usr/lib64/python3.6/__pycache__/inspect.cpython-36.opt-2.pyc

3


 \���@s�d�ZddlZddlZddlZddlZddlZddlZddl	Z	ddl
Z
ddlZddlZddl
Z
ddlZddlZddlZddlZddlZddlZddlmZddlmZmZe�Zx"ejj�D]\ZZeede<q�Wd�Zd	d
�Zdd�Z d
d�Z!dd�Z"dd�Z#e$ed��rdd�Z%ndd�Z%e$ed��r2dd�Z&ndd�Z&dd�Z'dd�Z(dd �Z)d!d"�Z*d#d$�Z+d%d&�Z,d'd(�Z-d)d*�Z.d+d,�Z/d-d.�Z0d/d0�Z1d1d2�Z2d3d4�Z3d5d6�Z4d�d7d8�Z5ed9d:�Z6d;d<�Z7d=d>�Z8dd?�d@dA�Z9dBdC�Z:dDdE�Z;dFdG�Z<dHdI�Z=dJdK�Z>dLdM�Z?dNdO�Z@dPdQ�ZAd�dRdS�ZBiZCiZDd�dTdU�ZEdVdW�ZFdXdY�ZGGdZd[�d[eH�ZIGd\d]�d]�ZJd^d_�ZKd`da�ZLdbdc�ZMddde�ZNd�dgdh�ZOedidj�ZPdkdl�ZQdmdn�ZRedodp�ZSdqdr�ZTedsdt�ZUdudv�ZVedwdx�ZWdydz�ZXd�d{d|�ZYd}d~�ZZdddfiie[dd��d�d��d�d��d�d��eYfd�d��Z\e[d�d��d�d��d�d��fd�d��Z]d�d��Z^d�d��Z_d�d��Z`ed�d��Zad�d��Zbed�d��Zcd�d�d��Zdd�d��Zeed�d�ecjf�Zgd�d�d��Zhd�d�d��Zid�d��Zjd�d�d��Zkd�d�d��Zlem�Znd�d��Zod�d��Zpd�d��Zqd�d��Zrd�d��Zsenfd�d��Ztd�Zud�Zvd�Zwd�Zxd�d��Zyd�d��Zzd�Z{d�Z|d�Z}d�Z~d�d��Zd�d„Z�e�e�j��Z�e�e�j��Z�e�e�j�d��Z�e�e�e�ej�fZ�d�dńZ�ffd�dDŽZ�d�dɄZ�d�d˄Z�d�d̈́Z�d�dτZ�d�dфZ��dd�dԄZ��dd�dքZ�d�d؄Z�d�d�dٜd�dۄZ�Gd�d݄d݃Z�Gd�d߄d߃Z�Gd�d�d�ej��Z�e�j�Z�e�j�Z�e�j�Z�e�j�Z�e�j�Z�e�d�e�d�e�d�e�d�e�d�iZ�e�j�Z�Gd�d�d�Z�Gd�d�d�Z�Gd�d�d�Z�d�d�d�d�Z�d�d�Z�e�d�k�r�e��dS(�Ka-Ping Yee <ping@lfw.org>�'Yury Selivanov <yselivanov@sprymix.com>�N)�
attrgetter)�
namedtuple�OrderedDictZCO_��cCst|tj�S)N)�
isinstance�types�
ModuleType)�object�r
�/usr/lib64/python3.6/inspect.py�ismodule@srcCs
t|t�S)N)r	�type)rr
r
r�isclassIsrcCst|tj�S)N)r	r
�
MethodType)rr
r
r�ismethodQsrcCs:t|�st|�st|�rdSt|�}t|d�o8t|d�S)NF�__get__�__set__)rr�
isfunctionr�hasattr)r�tpr
r
r�ismethoddescriptor[srcCs8t|�st|�st|�rdSt|�}t|d�o6t|d�S)NFrr)rrrrr)rrr
r
r�isdatadescriptorosr�MemberDescriptorTypecCst|tj�S)N)r	r
r)rr
r
r�ismemberdescriptorsrcCsdS)NFr
)rr
r
rr�s�GetSetDescriptorTypecCst|tj�S)N)r	r
r)rr
r
r�isgetsetdescriptor�srcCsdS)NFr
)rr
r
rr�scCst|tj�S)N)r	r
�FunctionType)rr
r
rr�srcCs tt|�st|�o|jjt@�S)N)�boolrr�__code__�co_flagsZCO_GENERATOR)rr
r
r�isgeneratorfunction�sr#cCs tt|�st|�o|jjt@�S)N)r rrr!r"ZCO_COROUTINE)rr
r
r�iscoroutinefunction�sr$cCs tt|�st|�o|jjt@�S)N)r rrr!r"ZCO_ASYNC_GENERATOR)rr
r
r�isasyncgenfunction�sr%cCst|tj�S)N)r	r
�AsyncGeneratorType)rr
r
r�
isasyncgen�sr'cCst|tj�S)N)r	r
�
GeneratorType)rr
r
r�isgenerator�sr)cCst|tj�S)N)r	r
�
CoroutineType)rr
r
r�iscoroutine�sr+cCs6t|tj�p4t|tj�r(t|jjt@�p4t|tj	j
�S)N)r	r
r*r(r �gi_coder"ZCO_ITERABLE_COROUTINE�collections�abc�	Awaitable)rr
r
r�isawaitable�sr0cCst|tj�S)N)r	r
�
TracebackType)rr
r
r�istraceback�sr2cCst|tj�S)N)r	r
�	FrameType)rr
r
r�isframe�sr4cCst|tj�S)N)r	r
�CodeType)rr
r
r�iscode�sr6cCst|tj�S)N)r	r
�BuiltinFunctionType)rr
r
r�	isbuiltinsr8cCs t|�pt|�pt|�pt|�S)N)r8rrr)rr
r
r�	isroutinesr9cCs�t|t�sdS|jt@rdStt|�tj�s0dSt|d�r>dSx&|jj	�D]\}}t
|dd�rJdSqJWx@|jD]6}x0t
|df�D] }t
||d�}t
|dd�r�dSq�WqnWdS)NFT�__abstractmethods__�__isabstractmethod__)r	r�	__flags__�TPFLAGS_IS_ABSTRACT�
issubclassr.�ABCMetar�__dict__�items�getattr�	__bases__)r�name�value�baser
r
r�
isabstract%s"


rGcCs&t|�r|ft|�}nf}g}t�}t|�}yBx<|jD]2}x,|jj�D]\}}t|tj	�rH|j
|�qHWq8WWntk
r�YnXx�|D]�}	yt||	�}
|	|kr�t�Wn:tk
r�x$|D]}|	|jkr�|j|	}
Pq�Ww�YnX|s�||
��r|j
|	|
f�|j
|	�q�W|jdd�d�|S)NcSs|dS)Nrr
)Zpairr
r
r�<lambda>fszgetmembers.<locals>.<lambda>)�key)r�getmro�set�dirrCr@rAr	r
�DynamicClassAttribute�append�AttributeErrorrB�add�sort)rZ	predicate�mro�results�	processed�namesrF�k�vrIrEr
r
r�
getmembers=s:




rX�	Attributezname kind defining_class objectcCs\t|�}tt|��}tdd�|D��}|f|}||}t|�}x:|D]2}x,|jj�D]\}}t|tj�rV|j	|�qVWqFWg}	t
�}
�x�|D�]�}d}d}
d}||
k�r�y|dkr�td��t||�}
Wn"tk
r�}zWYdd}~Xn�Xt|
d|�}||k�r�d}d}x(|D] }t||d�}||
k�r|}�qWxH|D]@}y|j
||�}Wntk
�rh�w:YnX||
k�r:|}�q:W|dk	�r�|}x4|D],}||jk�r�|j|}||k�r�|}P�q�W|dk�r�q�|
dk	�r�|
n|}t|t��r�d}|}n@t|t��rd}|}n*t|t��r"d}|}nt|��r2d	}nd
}|	j	t||||��|
j|�q�W|	S)NcSsg|]}|ttfkr|�qSr
)rr)�.0�clsr
r
r�
<listcomp>�sz(classify_class_attrs.<locals>.<listcomp>r@z)__dict__ is special, don't want the proxy�__objclass__z
static methodzclass method�property�method�data)rJr�tuplerLr@rAr	r
rMrNrK�	ExceptionrB�__getattr__rO�staticmethod�classmethodr^r9rYrP)r[rRZmetamroZclass_basesZ	all_basesrUrFrVrW�resultrTrDZhomeclsZget_objZdict_obj�excZlast_clsZsrch_clsZsrch_obj�obj�kindr
r
r�classify_class_attrsks�

















rjcCs|jS)N)�__mro__)r[r
r
rrJ�srJ)�stopcs��dkrdd�}n�fdd�}|}t|�|i}tj�}xD||�rz|j}t|�}||ksbt|�|krptdj|���|||<q8W|S)NcSs
t|d�S)N�__wrapped__)r)�fr
r
r�_is_wrapper�szunwrap.<locals>._is_wrappercst|d�o�|�S)Nrm)r)rn)rlr
rro�sz!wrapper loop when unwrapping {!r})�id�sys�getrecursionlimitrm�len�
ValueError�format)�funcrlrorn�memoZrecursion_limitZid_funcr
)rlr�unwrap�s

rxcCs|j�}t|�t|j��S)N)�
expandtabsrs�lstrip)�lineZexpliner
r
r�
indentsize	sr|cCsRtjj|j�}|dkrdSx&|jjd�dd�D]}t||�}q0Wt|�sNdS|S)N�.r���)rq�modules�get�
__module__�__qualname__�splitrBr)rvr[rDr
r
r�
_findclasssr�cCs�t|�rRxD|jD]:}|tk	ry
|j}Wntk
r<wYnX|dk	r|SqWdSt|�r�|jj}|j}t|�r�t	t	||d�d�|jkr�|}n|j
}n�t|�r�|j}t|�}|dks�t	||�|k	r�dSn�t
|��r
|j}|j}t|�o�|jd||jk�r|}n|j
}nzt|t��rJ|j}|j}t|�}|dk�sDt	||�|k	�r�dSn:t|��s^t|��r�|j}|j}t	||�|k	�r�dSndSxJ|jD]@}yt	||�j}Wntk
�r��w�YnX|dk	�r�|S�q�WdS)N�__func__r})rrkr�__doc__rOrr��__name__�__self__rB�	__class__rr�r8r�r	r^�fgetrrr])rhrF�docrD�selfr[rvr
r
r�_finddocsb




r�cCsdy
|j}Wntk
rdSX|dkrNyt|�}Wnttfk
rLdSXt|t�s\dSt|�S)N)r�rOr��	TypeErrorr	�str�cleandoc)rr�r
r
r�getdocSs

r�cCs�y|j�jd�}Wntk
r&dSXtj}x:|dd�D]*}t|j��}|r<t|�|}t||�}q<W|r~|dj�|d<|tjkr�x*tdt|��D]}|||d�||<q�Wx|r�|dr�|j	�q�Wx|r�|dr�|j	d�q�Wdj
|�SdS)N�
rrr~)ryr��UnicodeErrorrq�maxsizersrz�min�range�pop�join)r��linesZmarginr{Zcontent�indent�ir
r
rr�fs(
r�cCs�t|�r&t|d�r|jStdj|���t|�rdt|d�rVtjj|j	�}t|d�rV|jStdj|���t
|�rr|j}t|�r�|j
}t|�r�|j}t|�r�|j}t|�r�|jStdj|���dS)N�__file__z{!r} is a built-in moduler�z{!r} is a built-in classzO{!r} is not a module, class, method, function, traceback, frame, or code object)rrr�r�rurrqrr�r�rr�rr!r2�tb_framer4�f_coder6�co_filename)rr
r
r�getfile�s,


r�cCsTtjj|�}dd�tjj�D�}|j�x&|D]\}}|j|�r.|d|�Sq.WdS)NcSsg|]}t|�|f�qSr
)rs)rZ�suffixr
r
rr\�sz!getmodulename.<locals>.<listcomp>)�os�path�basename�	importlib�	machinery�all_suffixesrQ�endswith)r�Zfname�suffixesZneglenr�r
r
r�
getmodulename�s
r�cs�t|��tjjdd�}|tjjdd�7}t�fdd�|D��r`tjj��dtjj	d�nt�fdd�tjj
D��r~dStjj��r��Stt
|��dd�dk	r��S�tjkr��SdS)Nc3s|]}�j|�VqdS)N)r�)rZ�s)�filenamer
r�	<genexpr>�sz getsourcefile.<locals>.<genexpr>rc3s|]}�j|�VqdS)N)r�)rZr�)r�r
rr��s�
__loader__)r�r�r��DEBUG_BYTECODE_SUFFIXES�OPTIMIZED_BYTECODE_SUFFIXES�anyr�r��splitext�SOURCE_SUFFIXES�EXTENSION_SUFFIXES�existsrB�	getmodule�	linecache�cache)rZall_bytecode_suffixesr
)r�r�
getsourcefile�s
r�cCs,|dkrt|�pt|�}tjjtjj|��S)N)r�r�r�r��normcase�abspath)r�	_filenamer
r
r�
getabsfile�sr�c

Cs�t|�r|St|d�r$tjj|j�S|dk	rD|tkrDtjjt|�Syt||�}Wntk
rfdSX|tkr�tjjt|�Sxnt	tjj
��D]\\}}t|�r�t|d�r�|j}|tj|d�kr�q�|t|<t|�}|j
t|<ttjj|�<q�W|tk�r
tjjt|�Stjd}t|d��s$dSt||j
��rLt||j
�}||k�rL|Stjd}t||j
��r~t||j
�}	|	|k�r~|SdS)Nr�r��__main__r��builtins)rrrqrr�r��
modulesbyfiler�r��listrAr��_filesbymodnamer�r�r��realpathrB)
rr��file�modname�modulern�mainZ
mainobjectZbuiltinZ
builtinobjectr
r
rr��sD





r�c
Cs�t|�}|rtj|�n$t|�}|jd�o2|jd�s<td��t||�}|rZtj||j	�}n
tj|�}|sptd��t
|�r�|dfSt|��r |j}t
jd|d�}g}xRtt|��D]B}|j||�}|r�||ddkr�||fS|j|jd	�|f�q�W|�r|j�||dd	fStd
��t|��r0|j}t|��r@|j}t|��rP|j}t|��r`|j}t|��r�t|d��s~td��|jd	}	t
jd
�}x*|	dk�r�|j||	��r�P|	d	}	�q�W||	fStd��dS)N�<�>zsource code not availablezcould not get source coderz^(\s*)class\s*z\b�crzcould not find class definition�co_firstlinenoz"could not find function definitionz>^(\s*def\s)|(\s*async\s+def\s)|(.*(?<!\w)lambda(:|\s))|^(\s*@)zcould not find code object) r�r��
checkcacher��
startswithr��OSErrorr��getlinesr@rrr��re�compiler�rs�matchrN�grouprQrr�rr!r2r�r4r�r6rr�)
rr�r�r�rDZpatZ
candidatesr�r��lnumr
r
r�
findsource�s^









r�cCs>yt|�\}}Wnttfk
r(dSXt|�r�d}|rR|ddd�dkrRd}x(|t|�krz||j�dkrz|d}qTW|t|�kr�||dd�dkr�g}|}x>|t|�kr�||dd�dkr�|j||j��|d}q�Wdj|�S�nH|dk�r:t	||�}|d}|dk�r:||j
�dd�dk�r:t	||�|k�r:||j�j
�g}|dk�r�|d}||j�j
�}x\|dd�dk�r�t	||�|k�r�|g|dd�<|d}|dk�r�P||j�j
�}�q|Wx*|�r|dj�dk�rg|dd�<�q�Wx*|�r.|dj�dk�r.g|d	d�<�qWdj|�SdS)
Nr�z#!r��#)r�r�r~r~)r�r�r�rrs�striprNryr�r|rz)rr�r��startZcomments�endr�Zcommentr
r
r�getcommentsAsJ "
$
&
r�c@seZdZdS)�
EndOfBlockN)r�r�r�r
r
r
rr�nsr�c@seZdZdd�Zdd�ZdS)�BlockFindercCs.d|_d|_d|_d|_d|_d|_d|_dS)NrFr)r��islambda�started�passline�indecorator�decoratorhasargs�last)r�r
r
r�__init__rszBlockFinder.__init__cCs&|jrD|jrD|dkr d|_n|dkr<|dkr6d|_d|_d|_n�|dkrZ|jrXd|_n�|dkrv|jrtd|_d|_n�|tjkr�d|_|d	|_|jr�t�|jr�|jr�d|_nr|jr�nj|tj	kr�|j
d
|_
d|_nL|tjk�r|j
d
|_
|j
d	k�r"t�n"|j
d	k�r"|tjtj
fk�r"t�dS)N�@T�def�class�lambda�(�)Frr)r�r�r�)r�r�r�r�r��tokenize�NEWLINEr�r��INDENTr��DEDENT�COMMENT�NL)r�r�tokenZsrowcolZerowcolr{r
r
r�
tokeneater{sB


zBlockFinder.tokeneaterN)r�r�r�r�r�r
r
r
rr�ps	r�cCsZt�}y,tjt|�j�}x|D]}|j|�qWWnttfk
rJYnX|d|j�S)N)	r�r��generate_tokens�iter�__next__r�r��IndentationErrorr�)r�Zblockfinder�tokensZ_tokenr
r
r�getblock�s
r�cCsbt|�}t|�\}}t|�r"|j}t|�s>t|�rF|jjdkrF|dfSt||d��|dfSdS)Nz<module>rr)	rxr�r2r�rr4r��co_namer�)rr�r�r
r
r�getsourcelines�sr�cCst|�\}}dj|�S)Nr�)r�r�)rr�r�r
r
r�	getsource�sr�cCsVg}|jtdd�d�x:|D]2}|j||jf�||kr|jt||||��qW|S)Nr�r�)rI)rQrrNrC�walktree)�classes�children�parentrSr�r
r
rr��s
r�FcCs�i}g}xn|D]f}|jrbxZ|jD]<}||kr4g||<|||krN||j|�|r ||kr Pq Wq||kr|j|�qWx|D]}||kr~|j|�q~Wt||d�S)N)rCrNr�)r��uniquer��rootsr�rr
r
r�getclasstree�s"	

r�	Argumentszargs, varargs, varkwcCs t|�\}}}}t||||�S)N)�_getfullargsr)�co�args�varargs�
kwonlyargs�varkwr
r
r�getargs�src	Cs�t|�stdj|���|j}|j}|j}t|d|��}t||||��}d}||7}d}|jt@rx|j|}|d}d}|jt	@r�|j|}||||fS)Nz{!r} is not a code objectrr)
r6r�ru�co_argcount�co_varnames�co_kwonlyargcountr�r"�
CO_VARARGS�CO_VARKEYWORDS)	r�nargsrUZnkwargsrr	�steprr
r
r
rrs"



r�ArgSpeczargs varargs keywords defaultscCsDtjdtdd�t|�\}}}}}}}|s.|r6td��t||||�S)Nzhinspect.getargspec() is deprecated since Python 3.0, use inspect.signature() or inspect.getfullargspec()r�)�
stacklevelzdFunction has keyword-only parameters or annotations, use getfullargspec() API which can support them)�warnings�warn�DeprecationWarning�getfullargspecrtr)rvrrr
�defaultsr	�kwonlydefaults�annr
r
r�
getargspec s
r�FullArgSpeczGargs, varargs, varkw, defaults, kwonlyargs, kwonlydefaults, annotationsc
Cs`yt|ddtd�}Wn,tk
r@}ztd�|�WYdd}~XnXg}d}d}g}f}i}f}i}	|j|jk	rx|j|d<x�|jj�D]�}
|
j}|
j	}|t
kr�|j|�nv|tkr�|j|�|
j
|
jk	r�||
j
f7}nJ|tkr�|}n<|tk�r|j|�|
j
|
jk	�r|
j
|	|<n|tk�r|}|
j|
jk	r�|
j||<q�W|	�sBd}	|�sLd}t||||||	|�S)NF)�follow_wrapper_chains�skip_bound_arg�sigclszunsupported callable�return)�_signature_from_callable�	Signaturerbr��return_annotation�empty�
parameters�valuesrirD�_POSITIONAL_ONLYrN�_POSITIONAL_OR_KEYWORD�default�_VAR_POSITIONAL�
_KEYWORD_ONLY�_VAR_KEYWORD�
annotationr)
rv�sig�exrrr
r	r�annotations�
kwdefaults�paramrirDr
r
rrAsT





r�ArgInfozargs varargs keywords localscCs t|j�\}}}t||||j�S)N)rr�r4�f_locals)�framerrr
r
r
r�getargvalues�sr7cCsVt|dd�dkr t|�jdd�St|t�rN|jd|fkr>|jS|jd|jSt|�S)Nr�Ztypingztyping.r�r�r})rB�repr�replacer	rr�r�)r.Zbase_moduler
r
r�formatannotation�s
r:cst|dd���fdd�}|S)Nr�cs
t|��S)N)r:)r.)r�r
r�_formatannotation�sz5formatannotationrelativeto.<locals>._formatannotation)rB)rr;r
)r�r�formatannotationrelativeto�sr<cCsd|S)N�*r
)rDr
r
rrH�srHcCsd|S)Nz**r
)rDr
r
rrH�scCsdt|�S)N�=)r8)rEr
r
rrH�scCsd|S)Nz -> r
)�textr
r
rrH�sc
s(���fdd�}
g}|r(t|�t|�}xFt|�D]:\}}|
|�}|rb||krb||
|||�}|j|�q2W|dk	r�|j||
|���n|r�|jd�|r�x:|D]2}|
|�}|r�||kr�||
||�7}|j|�q�W|dk	r�|j|	|
|���ddj|�d}d�k�r$||��d��7}|S)Ncs(�|�}|�kr$|d��|�7}|S)Nz: r
)�argrf)r1r:�	formatargr
r�formatargandannotation�sz-formatargspec.<locals>.formatargandannotationr=r�z, r�r!)rs�	enumeraterNr�)rrr
rr	rr1rA�
formatvarargs�formatvarkw�formatvalueZ
formatreturnsr:rB�specsZfirstdefaultr�r@�specZ	kwonlyargrfr
)r1r:rAr�
formatargspec�s2


rIcCsd|S)Nr=r
)rDr
r
rrH�scCsd|S)Nz**r
)rDr
r
rrH�scCsdt|�S)Nr>)r8)rEr
r
rrH�scCs�|||fdd�}g}	x&tt|��D]}
|	j|||
��q"W|rZ|	j||�|||��|rx|	j||�|||��ddj|	�dS)NcSs||�|||�S)Nr
)rD�localsrArFr
r
r�convert�sz formatargvalues.<locals>.convertr�z, r�)r�rsrNr�)rrr
rJrArDrErFrKrGr�r
r
r�formatargvalues�srLcs��fdd�|D�}t|�}|dkr,|d}n>|dkr@dj|�}n*dj|dd��}|dd�=dj|�|}td	|||rzd
nd|dkr�dnd
|f��dS)Ncsg|]}|�krt|��qSr
)r8)rZrD)r'r
rr\�sz&_missing_arguments.<locals>.<listcomp>rrr�z	{} and {}z, {} and {}z, z*%s() missing %i required %s argument%s: %s�
positionalzkeyword-onlyr�r����rN)rsrur�r�)�f_nameZargnames�posr'rU�missingr��tailr
)r'r�_missing_arguments�s


rSc
	s�t|�|}t�fdd�|D��}|r:|dk}	d|f}
n2|rTd}	d|t|�f}
nt|�dk}	tt|��}
d}|r�d}||dkr�d	nd||dkr�d	ndf}td
||
|	r�d	nd|||dkr�|r�dndf��dS)
Ncsg|]}|�kr|�qSr
r
)rZr@)r'r
rr\sz_too_many.<locals>.<listcomp>rzat least %dTz
from %d to %dr�z7 positional argument%s (and %d keyword-only argument%s)r�z5%s() takes %s positional argument%s but %d%s %s givenZwasZwere)rsr�r�)
rOrZkwonlyrZdefcountZgivenr'ZatleastZkwonly_givenZpluralr/Z
kwonly_sig�msgr
)r'r�	_too_manys$rUcOs6|d}|dd�}t|�}|\}}}}}	}
}|j}i}
t|�rV|jdk	rV|jf|}t|�}t|�}|rrt|�nd}t||�}x t|�D]}|||
||<q�W|r�t||d��|
|<t||	�}|r�i|
|<xd|j	�D]X\}}||k�r|�st
d||f��||
||<q�||
k�r,t
d||f��||
|<q�W||k�r^|�r^t|||	||||
�||k�r�|d||�}x&|D]}||
k�r~t||d|
��q~Wx8t
|||d��D] \}}||
k�r�|||
|<�q�Wd}x>|	D]6}||
k�r�|
�r||
k�r|
||
|<n|d7}�q�W|�r2t||	d|
�|
S)Nrrz*%s() got an unexpected keyword argument %rz(%s() got multiple values for argument %rTF)rr�rr�rsr�r�rarKrAr�rUrSrC)Zfunc_and_positionalZnamedrvrMrHrrr
rr	rrrOZ	arg2valueZnum_posZnum_argsZnum_defaults�nr�Zpossible_kwargs�kwrEZreqr@rQ�kwargr
r
r�getcallargs!sd








rY�ClosureVarsz"nonlocals globals builtins unboundc	Cst|�r|j}t|�s$tdj|���|j}|jdkr:i}ndd�t|j|j�D�}|j	}|j
dtj�}t
|�rt|j}i}i}t�}xn|jD]d}|dkr�q�y||||<Wq�tk
r�y||||<Wntk
r�|j|�YnXYq�Xq�Wt||||�S)	Nz'{!r}' is not a Python functioncSsi|]\}}|j|�qSr
)�
cell_contents)rZ�varZcellr
r
r�
<dictcomp>vsz"getclosurevars.<locals>.<dictcomp>�__builtins__�None�True�False)r_r`ra)rr�rr�rur!�__closure__�zip�co_freevars�__globals__r�r�r@rrK�co_names�KeyErrorrPrZ)	rv�codeZ
nonlocal_varsZ	global_nsZ
builtin_nsZglobal_varsZbuiltin_varsZ
unbound_namesrDr
r
r�getclosurevarsas8	
ri�	Tracebackz+filename lineno function code_context indexcCs�t|�r|j}|j}n|j}t|�s2tdj|���t|�p@t|�}|dkr�|d|d}yt	|�\}}Wnt
k
r�d}}Yq�Xtdt|t
|�|��}||||�}|d|}nd}}t|||jj||�S)Nz'{!r} is not a frame or traceback objectrrr�)r2�	tb_linenor��f_linenor4r�rur�r�r�r��maxr�rsrjr�r�)r6�context�linenor�r�r�r��indexr
r
r�getframeinfo�s$rqcCs|jS)N)rl)r6r
r
r�	getlineno�srr�	FrameInfor6cCs6g}x,|r0|ft||�}|jt|��|j}qW|S)N)rqrNrs�f_back)r6rn�	framelist�	frameinfor
r
r�getouterframes�s
rwcCs8g}x.|r2|jft||�}|jt|��|j}qW|S)N)r�rqrNrs�tb_next)�tbrnrurvr
r
r�getinnerframes�s
rzcCsttd�rtjd�SdS)N�	_getframer)rrqr{r
r
r
r�currentframe�sr|cCsttjd�|�S)Nr)rwrqr{)rnr
r
r�stack�sr}cCsttj�d|�S)Nr�)rzrq�exc_info)rnr
r
r�trace�srcCstjdj|�S)Nrk)rr@r)�klassr
r
r�_static_getmro�sr�cCs8i}ytj|d�}Wntk
r(YnXtj||t�S)Nr@)r�__getattribute__rO�dictr��	_sentinel)rh�attrZ
instance_dictr
r
r�_check_instance�sr�cCsFx@t|�D]4}tt|��tkr
y
|j|Stk
r<Yq
Xq
WtS)N)r��_shadowed_dictrr�r@rg)r�r��entryr
r
r�_check_class�s

r�cCs&yt|�Wntk
r dSXdS)NFT)r�r�)rhr
r
r�_is_type�s
r�cCsntjd}x^t|�D]R}y|j|�d}Wntk
r>YqXt|�tjko`|jdko`|j|ks|SqWt	S)Nr@)
rr@r�rrgr
rr�r]r�)r��	dict_attrr�Z
class_dictr
r
rr�s


r�cCst}t|�s>t|�}t|�}|tks2t|�tjkrBt||�}n|}t||�}|tk	r�|tk	r�tt|�d�tk	r�tt|�d�tk	r�|S|tk	r�|S|tk	r�|S||kr�xDtt|��D]4}tt|��tkr�y
|j	|St
k
r�Yq�Xq�W|tk	r�|St|��dS)Nrr)r�r�rr�r
rr�r�r�r@rgrO)rhr�r*Zinstance_resultr�r�Zklass_resultr�r
r
r�getattr_statics6


r��GEN_CREATED�GEN_RUNNING�
GEN_SUSPENDED�
GEN_CLOSEDcCs,|jr
tS|jdkrtS|jjdkr(tStS)Nrr~)�
gi_runningr��gi_framer��f_lastir�r�)�	generatorr
r
r�getgeneratorstateGs	
r�cCs:t|�stdj|���t|dd�}|dk	r2|jjSiSdS)Nz '{!r}' is not a Python generatorr�)r)r�rurBr�r5)r�r6r
r
r�getgeneratorlocalsYsr��CORO_CREATED�CORO_RUNNING�CORO_SUSPENDED�CORO_CLOSEDcCs,|jr
tS|jdkrtS|jjdkr(tStS)Nrr~)�
cr_runningr��cr_framer�r�r�r�)�	coroutiner
r
r�getcoroutinestateqs	
r�cCs"t|dd�}|dk	r|jSiSdS)Nr�)rBr5)r�r6r
r
r�getcoroutinelocals�sr��
from_bytescCs6yt||�}Wntk
r"dSXt|t�s2|SdS)N)rBrOr	�_NonUserDefinedCallables)r[Zmethod_name�methr
r
r�"_signature_get_user_defined_method�s
r�cCs�|j}t|j��}|jpf}|jp$i}|r2||}y|j||�}Wn6tk
rx}zdj|�}	t|	�|�WYdd}~XnXd}
�x
|j�D�]�\}}y|j	|}
Wnt
k
r�YnlX|jtkr�|j
|�q�|jtk�r||kr�d}
|j|
d�||<n|j
|j�q�|jtk�r"|j|
d�||<|
r�|jtk�rV||jtd�}|||<|j|�q�|jttfk�rr|j|�q�|jtkr�|j
|j�q�W|j|j�d�S)Nz+partial object {!r} has incorrect argumentsFT)r*)ri)r&)r&rrAr�keywords�bind_partialr�rurt�	argumentsrgrir(r�r)r9rDr,�move_to_endr-r+r')�wrapped_sig�partialZ
extra_argsZ
old_params�
new_paramsZpartial_argsZpartial_keywordsZbar0rTZtransform_to_kwonly�
param_namer3Z	arg_valueZ	new_paramr
r
r�_signature_get_partial�sL






r�cCsnt|jj��}|s&|djttfkr.td��|dj}|ttfkrR|dd�}n|t	k	rbtd��|j
|d�S)Nrzinvalid method signaturerzinvalid argument type)r&)rar&r'rir-r,rtr)r(r+r9)r/�paramsrir
r
r�_signature_bound_method�s
r�cCs&t|�p$t|�p$t|t�p$|ttfkS)N)r8rr	r�rr)rhr
r
r�_signature_is_builtins
r�cCs�t|�st|�rdSt|dd�}t|dd�}t|dt�}t|dt�}t|dd�}t|tj�o�t|t�o�|dkszt|t�o�|dks�t|t	�o�t|t	�S)NFr�r!�__defaults__�__kwdefaults__�__annotations__)
�callablerrB�_voidr	r
r5r�rar�)rhrDrhrr2r1r
r
r�_signature_is_functionlike!s
r�cCs<|jd�}|dkr|jd�}|jd�}|jd�}|d|�S)N�,rr��:r>r�r~)�find)rHrPZcposr
r
r�_signature_get_bound_param:s




r�cCs$|s|ddfSd}d}dd�|jd�D�}t|�j}tj|�}d}d}g}|j}	d}
tj}tj}t|�}
x�|D]�}
|
j	|
j
}}||kr�|dkr�|r�d}qnd}|
d7}
qn|d	kr�d}|
d}qn||kr�|d
kr�|
}qn|r�d}||ko�|dks�|	d�|	|�|dkrn|	d
�qnWdj|�}|||fS)NcSsg|]}|jd��qS)�ascii)�encode)rZ�lr
r
rr\dsz6_signature_strip_non_python_syntax.<locals>.<listcomp>r�Frr�Tr�/�$r�z, � r�)r�r�r�r�rNr��OP�
ERRORTOKEN�nextr�stringr�)�	signature�self_parameter�last_positional_onlyr�r�Ztoken_streamZ
delayed_commaZskip_next_commar?rPZcurrent_parameterr�r��trr��clean_signaturer
r
r�"_signature_strip_non_python_syntaxQsP





r�TcsV|j�t|�\}}}d|d}ytj|�}Wntk
rFd}YnXt|tj�sbtdj|���|j	d}	g��j
�t��d}i�t|dd�}
|
r�t
jj|
d�}|r�|j�t
jj��dd����fdd	��	G�	fd
d�dtj���f�������fdd
�	}t|	jj�}t|	jj�}
tj||
dd�}|dk	�r8�j�n�j�x<ttt|���D](\}\}}|||�||k�rP�j��qPW|	jj�r��j�||	jj���j�x*t|	jj |	jj!�D]\}}|||��q�W|	jj"�r�j#�||	jj"��|dk	�rHt|dd�}|dk	}t$|�}|�r.|�s"|�r.�j%d�n�dj&�jd�}|�d<|�|j
d�S)Nzdef fooz: passz"{!r} builtin has invalid signaturerr�cSs|jdkrtd��|jS)Nz'Annotations are not currently supported)r.rtr@)�noder
r
r�
parse_name�s
z&_signature_fromstr.<locals>.parse_namecs�yt|��}Wn>tk
rLyt|��}Wntk
rFt��YnXYnXt|t�rbtj|�St|ttf�rztj	|�St|t
�r�tj|�S|dkr�tj|�St��dS)NTF)TFN)
�eval�	NameError�RuntimeErrorr	r��astZStr�int�floatZNum�bytesZBytesZNameConstant)r�rE)�module_dict�sys_module_dictr
r�
wrap_value�s 





z&_signature_fromstr.<locals>.wrap_valuecs$eZdZ�fdd�Z�fdd�ZdS)z,_signature_fromstr.<locals>.RewriteSymbolicscs`g}|}x"t|tj�r*|j|j�|j}q
Wt|tj�s>t��|j|j�dj	t
|��}�|�S)Nr})r	r�rYrNr�rE�Namer�rpr��reversed)r�r��arVrE)r�r
r�visit_Attribute�s
z<_signature_fromstr.<locals>.RewriteSymbolics.visit_Attributecst|jtj�st���|j�S)N)r	Zctxr�ZLoadrtrp)r�r�)r�r
r�
visit_Name�sz7_signature_fromstr.<locals>.RewriteSymbolics.visit_NameN)r�r�r�r�r�r
)r�r
r�RewriteSymbolics�sr�cs��|�}|�krdS|rp|tk	rpy��j|�}tj|�}Wntk
rR�}YnX|�kr`dS|�k	rl|n|}�j�|�|�d��dS)N)r*r.)�_emptyZvisitr�Zliteral_evalrtrN)Z	name_nodeZdefault_noder*rD�o)�	Parameterr�r%�invalidrir&r�r
r�p�s
z_signature_fromstr.<locals>.p)�	fillvaluer�)ri)r$)'�_parameter_clsr�r��parse�SyntaxErrorr	ZModulertruZbodyr%rrBrqrr�r@�copyZNodeTransformerr�rr�	itertools�zip_longest�POSITIONAL_ONLY�POSITIONAL_OR_KEYWORDrCr�Zvararg�VAR_POSITIONAL�KEYWORD_ONLYrcr	Zkw_defaultsrX�VAR_KEYWORDrr�r9)r[rhr�rr�r�r�Zprogramr�rnZmodule_namer�rrr�r�rDr*�_selfZself_isboundZ
self_ismoduler
)
r�r�r%r�rir�r&r�r�r�r�_signature_fromstr�sj








r�cCsBt|�stdj|���t|dd�}|s4tdj|���t||||�S)Nz%{!r} is not a Python builtin function�__text_signature__z#no signature found for builtin {!r})r�r�rurBrtr�)r[rvrr�r
r
r�_signature_from_builtin&sr�cCs�d}t|�s(t|�rd}ntdj|���|j}|j}|j}|j}t|d|��}|j	}||||�}	|j
}
|j}|j}|r�t
|�}
nd}
g}||
}x4|d|�D]$}|
j|t�}|j|||td��q�WxBt||d��D].\}}|
j|t�}|j|||t||d��q�W|jt@�rH|||}|
j|t�}|j|||td��xJ|	D]B}t}|dk	�rl|j|t�}|
j|t�}|j|||t|d���qNW|jt@�r�||}|jt@�r�|d7}||}|
j|t�}|j|||td��|||
jdt�|d	�S)
NFTz{!r} is not a Python functionr)r.ri)r.rir*rr!)r$�__validate_parameters__)rr�r�rur�r!rr
rarr�r�r�rsr�r�rNr)rCr"rr+r,rr-)r[rvZis_duck_functionr�Z	func_codeZ	pos_countZ	arg_namesrMZkeyword_only_countZkeyword_onlyr1rr2Zpos_default_countr&Znon_default_countrDr.�offsetr*rpr
r
r�_signature_from_function6sj










r�)rrc!Cs�t|�stdj|���t|tj�rDt|j|||d�}|r@t|�S|S|rtt	|dd�d�}t|tj�rtt||||d�Sy
|j
}Wntk
r�Yn&X|dk	r�t|t�s�tdj|���|Sy
|j
}Wntk
r�YnvXt|tj��rLt|j|||d�}t||d�}t|jj��d}|jtjk�r(|St|jj��}|f|}	|j|	d�St|��s`t|��rjt||�St|��r�t|||d	�St|tj��r�t|j|||d�}t||�Sd}t|t��r�t t|�d
�}
|
dk	�r�t|
|||d�}nJt |d�}|dk	�rt||||d�}n$t |d�}|dk	�r0t||||d�}|dk�r:xL|j!dd�D]:}
y
|
j"}Wntk
�rnYnX|�rJt#|||�S�qJWt|j!k�r:|j$t%j$k�r�|j&t%j&k�r�t't%�St(dj|���nrt|t)��s:t t|�d
�}
|
dk	�r:yt|
|||d�}Wn8t(k
�r8}zdj|�}t(|�|�WYdd}~XnX|dk	�rV|�rRt|�S|St|tj*��rvdj|�}t(|��t(dj|���dS)Nz{!r} is not a callable object)rrr cSs
t|d�S)N�
__signature__)r)rnr
r
rrH�sz*_signature_from_callable.<locals>.<lambda>)rlz1unexpected object {!r} in __signature__ attributer)r&)r�__call__�__new__r�rz(no signature found for builtin type {!r}zno signature found for {!r}z,no signature found for builtin function {!r}z+callable {!r} is not supported by signature)Nr~)+r�r�rur	r
rr"r�r�rxr�rOr#�_partialmethod�	functools�
partialmethodrvr�rar&r'rir�r�r9rr�r�r�r�r�rr�rkr�r�r�rr�r�rtr�r7)rhrrr r/r�r�Zfirst_wrapped_paramZ
sig_paramsr�Zcall�newZinitrFZtext_sigr0rTr
r
rr"�s�	



















r"c@seZdZdS)r�N)r�r�r�r
r
r
rr�P	sr�c@seZdZdS)r�N)r�r�r�r
r
r
rr�T	sr�c@s(eZdZdZdZdZdZdZdd�ZdS)	�_ParameterKindrrr���cCs|jS)N)�_name_)r�r
r
r�__str___	sz_ParameterKind.__str__N)	r�r�r�r�r�r�r�r�r�r
r
r
rr�X	sr�zpositional-onlyzpositional or keywordzvariadic positionalzkeyword-onlyzvariadic keywordc@s�eZdZd ZeZeZeZ	e
ZeZ
eZeed�dd�Zdd	�Zd
d�Zedd
��Zedd��Zedd��Zedd��Zeeeed�dd�Zdd�Zdd�Zdd�Zdd�ZdS)!r��_name�_kind�_default�_annotation)r*r.cCs"yt|�|_Wn$tk
r2td|�d���YnX|tk	rf|jttfkrfd}|jt|j��}t|��||_||_	|tkr�td��t
|t�s�djt|�j
�}t|��|ddko�|dd�j��r|jtkr�d	}|jt|j��}t|��t|_d
j|dd��}|j��stdj|���||_dS)Nzvalue z is not a valid Parameter.kindz({} parameters cannot have default valuesz*name is a required attribute for Parameterzname must be a str, not a {}rr}rzLimplicit arguments must be passed as positional or keyword arguments, not {}z
implicit{}z"{!r} is not a valid parameter name)r�rrtr�r+r-ru�_get_paramkind_descrrrr	r�rr�r��isdigitr)r(�isidentifierr)r�rDrir*r.rTr
r
rr��	s4


zParameter.__init__cCs t|�|j|jf|j|jd�fS)N)rr)rrrrr)r�r
r
r�
__reduce__�	s
zParameter.__reduce__cCs|d|_|d|_dS)Nrr)rr)r��stater
r
r�__setstate__�	s
zParameter.__setstate__cCs|jS)N)r)r�r
r
rrD�	szParameter.namecCs|jS)N)r)r�r
r
rr*�	szParameter.defaultcCs|jS)N)r)r�r
r
rr.�	szParameter.annotationcCs|jS)N)r)r�r
r
rri�	szParameter.kind)rDrir.r*cCsL|tkr|j}|tkr|j}|tkr*|j}|tkr8|j}t|�||||d�S)N)r*r.)r�rrrrr)r�rDrir.r*r
r
rr9�	szParameter.replacecCsj|j}|j}|jtk	r(dj|t|j��}|jtk	rDdj|t|j��}|tkrVd|}n|t	krfd|}|S)Nz{}:{}z{}={}r=z**)
rirrr�rur:rr8r+r-)r�ri�	formattedr
r
rr��	s


zParameter.__str__cCsdj|jj|�S)Nz	<{} "{}">)rur�r�)r�r
r
r�__repr__�	szParameter.__repr__cCst|j|j|j|jf�S)N)�hashrDrir.r*)r�r
r
r�__hash__�	szParameter.__hash__cCsJ||krdSt|t�stS|j|jkoH|j|jkoH|j|jkoH|j|jkS)NT)r	r��NotImplementedrrrr)r��otherr
r
r�__eq__
s
zParameter.__eq__N)rrrr)r�r�r��	__slots__r(r�r)r�r+r�r,r�r-r�r�r%r�rr	r^rDr*r.rir�r9r�rr
rr
r
r
rr�t	s((r�c@sdeZdZdZdd�Zedd��Zedd	��Zed
d��Zdd
�Z	dd�Z
dd�Zdd�Zdd�Z
dS)�BoundArgumentsr��
_signature�__weakref__cCs||_||_dS)N)r�r)r�r�r�r
r
rr�
szBoundArguments.__init__cCs|jS)N)r)r�r
r
rr�#
szBoundArguments.signaturecCs|g}xn|jjj�D]^\}}|jttfkr*Py|j|}Wntk
rNPYqX|jtkrf|j	|�q|j
|�qWt|�S)N)rr&rArir-r,r�rgr+�extendrNra)r�rr�r3r@r
r
rr'
s
zBoundArguments.argscCs�i}d}x�|jjj�D]x\}}|sF|jttfkr6d}n||jkrFd}q|sLqy|j|}Wntk
rnYqX|jtkr�|j|�q|||<qW|S)NFT)	rr&rArir-r,r�rg�update)r��kwargsZkwargs_startedr�r3r@r
r
rr>
s&

zBoundArguments.kwargscCs�|j}g}x�|jjj�D]v\}}y|j|||f�Wqtk
r�|jtk	rX|j}n"|jt	krhf}n|jt
krxi}nw|j||f�YqXqWt|�|_dS)N)r�rr&rArNrgr*r�rir+r-r)r�r�Z
new_argumentsrDr3�valr
r
r�apply_defaults\
s	


zBoundArguments.apply_defaultscCs2||krdSt|t�stS|j|jko0|j|jkS)NT)r	rrr�r�)r�rr
r
rrx
s
zBoundArguments.__eq__cCs|d|_|d|_dS)Nrr�)rr�)r�rr
r
rr	�
s
zBoundArguments.__setstate__cCs|j|jd�S)N)rr�)rr�)r�r
r
r�__getstate__�
szBoundArguments.__getstate__cCsDg}x(|jj�D]\}}|jdj||��qWdj|jjdj|��S)Nz{}={!r}z	<{} ({})>z, )r�rArNrur�r�r�)r�rr@rEr
r
rr�
szBoundArguments.__repr__N)r�rr)r�r�r�rr�r^r�rrrrr	rrr
r
r
rr
src@s�eZdZd,ZeZeZeZ	d-edd�dd�Z
edd	��Zed
d��Z
edd�d
d��Zedd��Zedd��Zeed�dd�Zdd�Zdd�Zdd�Zdd�dd�Zd d!�Zd"d#�Zd$d%�Zd&d'�Zd(d)�Zd*d+�ZdS).r#�_return_annotation�_parametersNT)r$r�cCs�|dkrt�}n�|r�t�}t}d}x�t|�D]�\}}|j}	|j}
|	|krjd}|jt|�t|	��}t|��n|	|krzd}|	}|	ttfkr�|j	t
kr�|r�d}t|��nd}|
|kr�dj|
�}t|��|||
<q,Wntdd�|D��}tj|�|_
||_dS)NFz7wrong parameter order: {} parameter before {} parameterz-non-default argument follows default argumentTzduplicate parameter name: {!r}css|]}|j|fVqdS)N)rD)rZr3r
r
rr��
sz%Signature.__init__.<locals>.<genexpr>)rr(rCrirDrurrtr)r*r�r
�MappingProxyTyperr)r�r&r$r�r�Ztop_kindZ
kind_defaults�idxr3rirDrTr
r
rr��
s>






zSignature.__init__cCstjdtdd�t||�S)Nz_inspect.Signature.from_function() is deprecated since Python 3.5, use Signature.from_callable()r�)r)rrrr�)r[rvr
r
r�
from_function�
s
zSignature.from_functioncCstjdtdd�t||�S)Nz^inspect.Signature.from_builtin() is deprecated since Python 3.5, use Signature.from_callable()r�)r)rrrr�)r[rvr
r
r�from_builtin�
s
zSignature.from_builtin)�follow_wrappedcCst|||d�S)N)r r)r")r[rhr!r
r
r�
from_callable�
szSignature.from_callablecCs|jS)N)r)r�r
r
rr&szSignature.parameterscCs|jS)N)r)r�r
r
rr$szSignature.return_annotation)r&r$cCs0|tkr|jj�}|tkr |j}t|�||d�S)N)r$)r�r&r'rr)r�r&r$r
r
rr9	s
zSignature.replacecCs8tdd�|jj�D��}dd�|jj�D�}|||jfS)Ncss|]}|jtkr|VqdS)N)rir,)rZr3r
r
rr�sz(Signature._hash_basis.<locals>.<genexpr>cSsi|]}|jtkr||j�qSr
)rir,rD)rZr3r
r
rr]sz)Signature._hash_basis.<locals>.<dictcomp>)rar&r'r$)r�r��
kwo_paramsr
r
r�_hash_basisszSignature._hash_basiscCs(|j�\}}}t|j��}t|||f�S)N)r$�	frozensetr'r)r�r�r#r$r
r
rr
!szSignature.__hash__cCs*||krdSt|t�stS|j�|j�kS)NT)r	r#rr$)r�rr
r
rr&s

zSignature.__eq__F)r�cCs�t�}t|jj��}f}t|�}�xxyt|�}Wn�tk
r�yt|�}	Wntk
rbPYn�X|	jtkrrPn�|	j|kr�|	jt	kr�d}
|
j
|	jd�}
t|
�d�|	f}PnH|	jtks�|	j
tk	r�|	f}Pn*|r�|	f}Pnd}
|
j
|	jd�}
t|
�d�Yq$Xyt|�}	Wn tk
�r&td�d�Yq$X|	jttfk�rBtd�d�|	jtk�rn|g}|j|�t|�||	j<P|	j|k�r�tdj
|	jd��d�|||	j<q$Wd}x�tj||�D]�}	|	jtk�r�|	}�q�|	jtk�r֐q�|	j}
y|j|
�}WnHtk
�r2|�r.|	jtk�r.|	j
tk�r.tdj
|
d��d�Yn(X|	jt	k�rRtdj
|	jd���|||
<�q�W|�r�|dk	�r||||j<ntdj
tt|��d���|j||�S)NzA{arg!r} parameter is positional only, but was passed as a keyword)r@z$missing a required argument: {arg!r}ztoo many positional argumentsz$multiple values for argument {arg!r}z*got an unexpected keyword argument {arg!r})rr�r&r'r��
StopIterationrir+rDr(rur�r-r*r�r,rrar��chainr�rg�_bound_arguments_cls)r�rrr�r�r&Z
parameters_exZarg_valsZarg_valr3rTr'Zkwargs_paramr�r
r
r�_bind-s�







zSignature._bindcOs|dj|dd�|�S)Nrr)r))rrr
r
r�bind�szSignature.bindcOs|dj|dd�|dd�S)NrrT)r�)r))rrr
r
rr��szSignature.bind_partialcCs t|�t|jj��fd|jifS)Nr)rrarr'r)r�r
r
rr�szSignature.__reduce__cCs|d|_dS)Nr)r)r�rr
r
rr	�szSignature.__setstate__cCsdj|jj|�S)Nz<{} {}>)rur�r�)r�r
r
rr�szSignature.__repr__c	Cs�g}d}d}xr|jj�D]d}t|�}|j}|tkr8d}n|rJ|jd�d}|tkrXd}n|tkrr|rr|jd�d}|j|�qW|r�|jd�djdj	|��}|j
tk	r�t|j
�}|dj|�7}|S)NFTr�r=z({})z, z -> {})
r&r'r�rir(rNr+r,rur�r$r�r:)	r�rfZrender_pos_only_separatorZrender_kw_only_separatorr3r
riZrenderedZannor
r
rr��s0




zSignature.__str__)rr)N)r�r�r�rr�r�rr(r�r%r�rerr r"r^r&r$r�r9r$r
rr)r*r�rr	rr�r
r
r
rr#�
s06	r#)r!cCstj||d�S)N)r!)r#r")rhr!r
r
rr��sr�cCs�ddl}ddl}|j�}|jddd�|jddddd	�|j�}|j}|jd
�\}}}y|j|�}}	WnLtk
r�}
z0dj	|t
|
�j|
�}t|t
jd�td
�WYdd}
~
XnX|r�|jd�}|	}x|D]}
t||
�}q�W|	jt
jk�rtdt
jd�td�|j�r�tdj	|��tdj	t|	���tdj	|	j��||	k�rxtdj	t|	j���t|	d��r�tdj	|	j��n6yt|�\}}Wntk
�r�YnXtdj	|��td�ntt|��dS)NrrzCThe object to be analysed. It supports the 'module:qualname' syntax)�helpz-dz	--details�
store_truez9Display info about the module rather than its source code)�actionr+r�zFailed to import {} ({}: {}))r�r�r}z#Can't get info for builtin modules.rz
Target: {}z
Origin: {}z
Cached: {}z
Loader: {}�__path__zSubmodule search path: {}zLine: {}r�)�argparser��ArgumentParser�add_argument�
parse_argsr�	partition�
import_modulerbrurr��printrq�stderr�exitr�rB�builtin_module_namesZdetailsr��
__cached__r8r�rr.r�r�)r/r��parserr�targetZmod_nameZ	has_attrsZattrsrhr�rgrT�parts�part�__ror
r
r�_main�sV



r?r�)rri)N)N)N)F)N)r)r6)r)r)r)r)T)T)��
__author__r.r�Zdis�collections.abcr-�enum�importlib.machineryr�r�r�r�r�rqr�r�r
rr�r��operatorrrr�globalsZmod_dictZCOMPILER_FLAG_NAMESrArVrWr=rrrrrrrrrr#r$r%r'r)r+r0r2r4r6r8r9rGrXrYrjrJrxr|r�r�r�r�r�r�r�r�r�r�r�r�r�rbr�r�r�r�r�r�rrrrrrrrr4r7r:r<r�rIrLrSrUrYrZrirjrqrr�_fieldsrsrwrzr|r}rrr�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�rr�Z_WrapperDescriptor�allZ_MethodWrapperr�r@Z_ClassMethodWrapperr7r�r�r�r�r�r�r�r�r�r�r�r"r�r��IntEnumr�r�r(r�r)r�r+r�r,r�r-Z_PARAM_NAME_MAPPING�__getitem__rr�rr#r�r?r�r
r
r
r�<module>sd	



	
	
,
t$
;
	
.I-7





[


	(>
5

 



		0

LHRHk: