[PyKDE] SIP: MappedType for pointers?

Giovanni Bajo rasky at develer.com
Tue Mar 21 18:23:53 GMT 2006


Hello,

I'm writing a SIP wrapper for a serie of overloaded functions like this:

void Foo(char *str);
void Foo(wchar_t *str);

void Bar(char *str);
void Bar(wchar_t *str);

[etc.]

Python supports conversion to/from wchar_t buffers using
PyUnicode_From/AsWideChar, but SIP does not support it. Could this be added
automatically?

This notwithstanding, I couldn't find a way to use %MappedType to solve my
problem, without having to write many duplicated %MappedCode. Any pointer?
-- 
Giovanni Bajo




More information about the PyQt mailing list