On 10/05/2011 09:18 AM, Jim Bosch wrote:
I have one (perhaps unusual) use case that's extremely important for me: I have a templated matrix/vector/array class, and I want to define converters between those types and numpy that work with any combination of template parameters. I can do that with compile-time converters, and after including the header everything just works. With runtime conversions, I have to explicitly declare all the template parameter combinations I intend to use.
Jim, I may be a little slow here, but I still don't see the issue. You need to export your classes to Python one at a time anyhow, i.e. not as a template, letting the Python runtime figure out all valid template argument permutations. So why can't the converter definitions simply be bound to those type definitions ? Thanks, Stefan -- ...ich hab' noch einen Koffer in Berlin...