Viewing File: /opt/alt/python35/lib64/python3.5/lib2to3/fixes/__pycache__/fix_renames.cpython-35.opt-2.pyc



й¼]­ã@ssddlmZddlmZmZdddiiZiZdd„Zdd	„ZGd
d„dej	ƒZ
dS)
é)Ú
fixer_base)ÚNameÚ
attr_chainÚsysZmaxintÚmaxsizecCsddjtt|ƒƒdS)Nú(ú|ú))ÚjoinÚmapÚrepr)Úmembers©rú0/opt/alt/python35/lib64/python3.5/fix_renames.pyÚ
alternatessrccs{xtttjƒƒD]`\}}xQt|jƒƒD]=\}}|t||f<d|||fVd||fVq2WqWdS)Nz£
                  import_from< 'from' module_name=%r 'import'
                      ( attr_name=%r | import_as_name< attr_name=%r 'as' any >) >
                  z^
                  power< module_name=%r trailer< '.' attr_name=%r > any* >
                  )ÚlistÚMAPPINGÚitemsÚLOOKUP)ÚmoduleÚreplaceZold_attrÚnew_attrrrrÚ
build_patterns

rcsLeZdZdZdjeƒƒZdZ‡fdd†Zdd„Z	‡S)Ú
FixRenamesTrÚprecsXtt|ƒj‰ˆ|ƒ}|rTt‡fdd†t|dƒDƒƒrPdS|SdS)Nc3s|]}ˆ|ƒVqdS)Nr)Ú.0Úobj)Úmatchrrú	<genexpr>5sz#FixRenames.match.<locals>.<genexpr>ÚparentF)ÚsuperrrÚanyr)ÚselfÚnodeÚresults)Ú	__class__)rrr1s(zFixRenames.matchcCs`|jdƒ}|jdƒ}|r\|r\t|j|jf}|jt|d|jƒƒdS)NÚmodule_nameÚ	attr_nameÚprefix)ÚgetrÚvaluerrr()r"r#r$Zmod_namer'rrrrÚ	transform>s
zFixRenames.transform)
Ú__name__Ú
__module__Ú__qualname__Z
BM_compatibler
rZPATTERNÚorderrr+rr)r%rr*s

rN)ÚrZ
fixer_utilrrrrrrZBaseFixrrrrrÚ<module>
s
Back to Directory File Manager