En Mon, 27 Aug 2007 15:59:25 -0300, Abel Daniel <[EMAIL PROTECTED]>  
escribi�:

> Hi!
>
> A python interactive interpreter works by having the user type in some
> code, compiling and running that code, then printing the results. For
> printing, the results are turned into strings.

This last stage is done by calling sys.displayhook - you can replace that  
function with your own one, and get the object to be printed.
Any of your previous attempts (using compile(...,"single")+eval, using  
exec, or creating your own code.InteractiveInterpreter) should work with  
this.

-- 
Gabriel Genellina

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to