[C++-sig] Unicode strings
Andreas Beyer
beyer at imb-jena.de
Mon May 26 13:44:35 CEST 2003
Hi,
Is it possible to convert a python unicode object to a C++ string object?
If yes: How do I do that?
If no: Would it be possible to include unicode support into the string
wrapper class in Boost.Python?
Thanks,
Andreas
PS: Apperently the following does not work:
class my_class
{
...
void take_a_string(string);
...
}
Then in the wrapper:
.def("take_a_string", &my_class::take_a_string)
And finally in Python:
>>> x = my_class()
>>> x.take_a_string(unicode("something"))
-> TypeError
More information about the Cplusplus-sig
mailing list