Boost logo

Boost Users :

From: Ran Regev (regev.ran_at_[hidden])
Date: 2023-06-29 14:31:12


Hi,

The code in construct() seems to surfer from copy/paste or merge error.
It seems as though the following lines are duplicated in the else clause:

      void *const storage =
((converter::rvalue_from_python_storage<SP<T> >*)data)->storage.bytes;
      // Deal with the "None" case.
      if (data->convertible == source)
        new (storage) SP<T>();

Please take a look at:
https://www.boost.org/doc/libs/1_82_0/boost/python/converter/shared_ptr_from_python.hpp

Ran.



Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net