%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /usr/local/lib/python2.7/lib2to3/fixes/
Upload File :
Create Path :
Current File : //usr/local/lib/python2.7/lib2to3/fixes/fix_next.pyo

σ
Pκαac@sdZddlmZddlmZddlmZddlm	Z	m
Z
mZdZdej
fd„ƒYZd	„Zd
„Zd„ZdS(
s.Fixer for it.next() -> next(it), per PEP 3114.i(ttoken(tpython_symbols(t
fixer_base(tNametCalltfind_bindings;Calls to builtin next() possibly shadowed by global bindingtFixNextcBs,eZeZdZdZd„Zd„ZRS(sΎ
    power< base=any+ trailer< '.' attr='next' > trailer< '(' ')' > >
    |
    power< head=any+ trailer< '.' attr='next' > not trailer< '(' ')' > >
    |
    classdef< 'class' any+ ':'
              suite< any*
                     funcdef< 'def'
                              name='next'
                              parameters< '(' NAME ')' > any+ >
                     any* > >
    |
    global=global_stmt< 'global' any* 'next' any* >
    tprecCsWtt|ƒj||ƒtd|ƒ}|rJ|j|tƒt|_n	t|_dS(Nunext(	tsuperRt
start_treeRtwarningtbind_warningtTruet
shadowed_nexttFalse(tselfttreetfilenametn((s2/usr/local/lib/python2.7/lib2to3/fixes/fix_next.pyR	$scCsƒ|jdƒ}|jdƒ}|jdƒ}|r―|jr[|jtdd|jƒƒqg|D]}|jƒ^qb}d|d_|jttdd|jƒ|ƒƒnΠ|rΪtdd|jƒ}|j|ƒn₯|rWt|ƒrA|d	}d
jg|D]}t	|ƒ^qƒj
ƒdkr=|j|tƒndS|jtdƒƒn(d|kr|j|tƒt
|_ndS(
Ntbasetattrtnameu__next__tprefixuiunexttheadtu__builtin__tglobal(tgetR
treplaceRRtcloneRtis_assign_targettjointstrtstripR
RR(RtnodetresultsRRRRR((s2/usr/local/lib/python2.7/lib2to3/fixes/fix_next.pyt	transform.s,	
(
4(t__name__t
__module__Rt
BM_compatibletPATTERNtorderR	R#(((s2/usr/local/lib/python2.7/lib2to3/fixes/fix_next.pyRs
	
cCs]t|ƒ}|dkrtSx:|jD]/}|jtjkrBtSt||ƒr&tSq&WtS(N(	tfind_assigntNoneRtchildrenttypeRtEQUALt
is_subtreeR(R!tassigntchild((s2/usr/local/lib/python2.7/lib2to3/fixes/fix_next.pyRQscCsH|jtjkr|S|jtjks7|jdkr;dSt|jƒS(N(R,tsymst	expr_stmttsimple_stmttparentR*R)(R!((s2/usr/local/lib/python2.7/lib2to3/fixes/fix_next.pyR)]s
!cs-|ˆkrtSt‡fd†|jDƒƒS(Nc3s|]}t|ˆƒVqdS(N(R.(t.0tc(R!(s2/usr/local/lib/python2.7/lib2to3/fixes/fix_next.pys	<genexpr>gs(RtanyR+(trootR!((R!s2/usr/local/lib/python2.7/lib2to3/fixes/fix_next.pyR.dsN(t__doc__tpgen2RtpygramRR1RRt
fixer_utilRRRRtBaseFixRRR)R.(((s2/usr/local/lib/python2.7/lib2to3/fixes/fix_next.pyt<module>s@		

Zerion Mini Shell 1.0