Exposing BOOST_STRONG_TYPEDEF types.
March 23, 2005
2:55 a.m.
Hi all, I have some types that I have created with BOOST_STRONG_TYPEDEF. I want to manipulate these types from Python, but given that they are not built-in data types, Boost.Python cannot implicitly handle them. So what I want to do is, given BOOST_STRONG_TYPEDEF(size_t, ID) for example, expose this as an 'int'. I suppose you would want to do something like: class_<ID, bases<size_t> >("ID"); It seems you can derive from a built-in data type in Python, I'm not sure what this actually does to the class though. (not a python expert :) ) Does anyone know if there is a 'proper' way to do this with Boost.Python? kalin
7689
Age (days ago)
7689
Last active (days ago)
0 comments
1 participants
participants (1)
-
kalin