[C++-sig] Boost Python Tuple - Find length of tuple?

Simon Pickles sipickles at googlemail.com
Mon Jan 4 15:24:50 CET 2010


On 04/01/2010 14:02, Brian O'Kennedy wrote:
> You could try this instead: (untested!)
>
>       using namespace boost::python;
>       tuple a = make_tuple("hello", 42);
>       std::cout << "Length = " << boost::python::len(a) << std::endl; 
>  // explicit namespace not needed
>
>
Thanks, thats perfect.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/cplusplus-sig/attachments/20100104/c7cc28d1/attachment.htm>


More information about the Cplusplus-sig mailing list