If you're doing the logging from within C#, then there's no way to recover
the originally-passed Python object if the binder has had to perform a
conversion -- as it will have in this case.
On Tue, Jan 27, 2009 at 8:41 PM, Jeff Slutter wrote:
> Curt Hagenlocher wrote:
> > If you're willing to liv
Curt Hagenlocher wrote:
> If you're willing to live on the bleeding edge and build from the latest
> sources, it turns out that Tomas just added this functionality to the
> hosting interfaces yesterday. ObjectOperations.Format(obj) should return
> a string that matches what the REPL would have prin
---
From: users-boun...@lists.ironpython.com
[mailto:users-boun...@lists.ironpython.com] On Behalf Of Jimmy Schementi
Sent: Tuesday, January 27, 2009 7:56 PM
To: Discussion of IronPython
Subject: Re: [IronPython] Printing an object out as a string
repr([0,1,2])
> -Original Message-
If you're willing to live on the bleeding edge and build from the latest
sources, it turns out that Tomas just added this functionality to the
hosting interfaces yesterday. ObjectOperations.Format(obj) should return a
string that matches what the REPL would have printed.
On Tue, Jan 27, 2009 at 7:
repr([0,1,2])
> -Original Message-
> From: users-boun...@lists.ironpython.com [mailto:users-
> boun...@lists.ironpython.com] On Behalf Of Jeff Slutter
> Sent: Tuesday, January 27, 2009 7:53 PM
> To: Discussion of IronPython
> Subject: [IronPython] Printing an obje
Given an object, how can I go about printing out that object as a string
representing the object in Python syntax?
I need something a little more powerful than just object.ToString()
I need something like how the interactive console reports the result of
the statement.
For instance:
a = [0,1,2]