Ñò §ÚêLc@s{dZddklZddklZddklZddklZlZl Z l Z l Z dei fd„ƒYZ dS( s-Fixer for 'raise E, V, T' raise -> raise raise E -> raise E raise E, V -> raise E(V) raise E, V, T -> raise E(V).with_traceback(T) raise (((E, E'), E''), E'''), V -> raise E(V) raise "foo", V, T -> warns about string exceptions CAVEATS: 1) "raise E, V" will be incorrectly translated if V is an exception instance. The correct Python 3 idiom is raise E from V but since we can't detect instance-hood by syntax alone and since any client code would have to be changed as well, we don't automate this. i(tpytree(ttoken(t fixer_base(tNametCalltAttrtArgListtis_tupletFixRaisecBseZdZd„ZRS(sB raise_stmt< 'raise' exc=any [',' val=any [',' tb=any]] > c Csï|i}|diƒ}|itijo|i|dƒdSt|ƒo<x,t|ƒo|ididiƒ}qQWd|_nd|jo2t i |i t dƒ|gƒ}|i|_|S|diƒ}t|ƒo5g}|idd!D]}||iƒqû~} nd |_|g} d |jo€|d iƒ} d | _t || ƒ} t| t d ƒƒt| gƒg} t i |it dƒg| ƒ}|i|_|St i |i t dƒt || ƒgd |iƒSdS( Ntexcs+Python 3 does not support string exceptionsiit tvaluraiseiÿÿÿÿuttbuwith_tracebacktprefix(tsymstclonettypeRtSTRINGtcannot_convertRtchildrenR RtNodet raise_stmtRRRRt simple_stmt( tselftnodetresultsRR tnewR t_[1]tctargsR tetwith_tb((s//usr/lib64/python2.6/lib2to3/fixes/fix_raise.pyt transform$s<     !  5    %"  (t__name__t __module__tPATTERNR (((s//usr/lib64/python2.6/lib2to3/fixes/fix_raise.pyRsN(t__doc__tRtpgen2RRt fixer_utilRRRRRtBaseFixR(((s//usr/lib64/python2.6/lib2to3/fixes/fix_raise.pyts (