Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r53322 - sandbox-branches/bhy/py3k/boost/python/object
From: divinekid_at_[hidden]
Date: 2009-05-27 15:43:53


Author: bhy
Date: 2009-05-27 15:43:52 EDT (Wed, 27 May 2009)
New Revision: 53322
URL: http://svn.boost.org/trac/boost/changeset/53322

Log:
fix for next() -> __next__() name change in py3k
Text files modified:
   sandbox-branches/bhy/py3k/boost/python/object/iterator.hpp | 4 ++++
   1 files changed, 4 insertions(+), 0 deletions(-)

Modified: sandbox-branches/bhy/py3k/boost/python/object/iterator.hpp
==============================================================================
--- sandbox-branches/bhy/py3k/boost/python/object/iterator.hpp (original)
+++ sandbox-branches/bhy/py3k/boost/python/object/iterator.hpp 2009-05-27 15:43:52 EDT (Wed, 27 May 2009)
@@ -129,7 +129,11 @@
       return class_<range_>(name, no_init)
           .def("__iter__", identity_function())
           .def(
+#if PY_VERSION_HEX >= 0x03000000
+ "__next__"
+#else
               "next"
+#endif
             , make_function(
                 next_fn()
               , policies


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk