Re: [C++-sig] [Boost.Python] Adding a constructor to python object

2013-03-05 Thread Neal Becker
Александров Петр wrote: > I want to create a Python interface for > "boost::numeric::ublas::vector" Not a direct answer to your question, but you might like pyUblas ___ Cplusplus-sig mailing list Cplusplus-sig@python.org http://mail.python.org/mailman/l

[C++-sig] [Boost.Python] Adding a constructor to python object

2013-03-05 Thread Александров Петр
I want to create a Python interface for "boost::numeric::ublas::vector" where TReal is a C++ class for numbers. How can I add my constructor (to create a vector from a python list) to the python interface for "ublas::vector"? The following approach: class_("vector") .def(init()) .def(i