On Wed, Apr 29, 2009 at 9:33 AM, Dino Viehland <di...@microsoft.com> wrote: > On 18222 - I think ctypes will drive some changes to our buffer support > making it more real. Right now it's close to useless :) There is some > way for us to make types marshalable via COM ourselves so I think > we'll be able to fix it eventually. I'm surprised that it's more of > a problem than 18223 though. >
As Jeff said, it's a question of cluttering up the code. pywin32 C code does a lot of work converting Python objects into/from COM compatible types. IronPython COM calls do not have the extra layer of help. For example, in adodbapi the workaround for 18223 is: elif isinstance(elem, longType) and onIronPython: # Iron Python Long s = SystemDecimal(elem) # feature workaround for IPy 2.0 p.Value = s else: p.Value=elem Note that when converted to Python 3, this effectively becomes: elif isinstance(elem, int) and onIronPython: # Iron Python integer s = SystemDecimal(elem) # feature workaround for IPy 2.0 p.Value = s else: p.Value=elem so that ALL integers will be run thru SystemDecimal before use as a COM parameter. Clearly this will need to be fixed before IronPython 3.0... -- Vernon _______________________________________________ Users mailing list Users@lists.ironpython.com http://lists.ironpython.com/listinfo.cgi/users-ironpython.com