ó o”þfc@sCdZddlmZddlmZdejfd„ƒYZdS(s,Fixer that cleans up a tuple argument to isinstance after the tokens in it were fixed. This is mainly used to remove double occurrences of tokens as a leftover of the long -> int / unicode -> str conversion. eg. isinstance(x, (int, long)) -> isinstance(x, (int, int)) -> isinstance(x, int) i(t fixer_base(ttokent FixIsinstancecBs#eZeZdZdZd„ZRS(s˜ power< 'isinstance' trailer< '(' arglist< any ',' atom< '(' args=testlist_gexp< any+ > ')' > > ')' > > ic CsUtƒ}|d}|j}g}t|ƒ}xª|D]¢\}} | jtjkr¥| j|kr¥|t|ƒdkr×||djtjkr×|j ƒq5q×q5|j | ƒ| jtjkr5|j | jƒq5q5W|r|djtjkr|d=nt|ƒdkr@|j } | j |d_ | j|dƒn||(|jƒdS(Ntargsiiÿÿÿÿi(tsettchildrent enumeratettypeRtNAMEtvaluetlentCOMMAtnexttappendtaddtparenttprefixtreplacetchanged( tselftnodetresultstnames_insertedttestlistRtnew_argstiteratortidxtargtatom((s4/usr/lib64/python2.7/lib2to3/fixes/fix_isinstance.pyt transforms*    !0     (t__name__t __module__tTruet BM_compatibletPATTERNt run_orderR(((s4/usr/lib64/python2.7/lib2to3/fixes/fix_isinstance.pyRsN(t__doc__tRt fixer_utilRtBaseFixR(((s4/usr/lib64/python2.7/lib2to3/fixes/fix_isinstance.pyt s