[C++-sig] enums and structs

Achim Domma achim.domma at syynx.de
Sat May 18 18:42:32 CEST 2002


 Hi,
 
 in ./test/comprehensiv.cpp I found the following example for 
 exposing enums:
 
 namespace boost { namespace python {
   template class enum_as_int_converters<bpl_test::EnumOwner::enum_type>;
   using bpl_test::pow;
 }} // namespace boost::python
 
 in Daves progress report from march he mentioned a new interface 
 for exposing enums. Is the code above the right one or will the 
 interface change in V2 ? comprehensive.cpp was the only example 
 concerning enums I could find in the testfolder.
 
 I also have to expose structs with char* members. Is that 
 possible ? It would be no problem to make a copy of the string 
 passed from python, but how/when will this copy be destroyed ?
 
 greetings
 Achim
 
 PS.: I'm trying to make ImageMagick accessible from Python, which 
 is much more work than I expected, but I'm also learning much 
 more than I expected! ;-)






More information about the Cplusplus-sig mailing list