Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add non-copyable type support in std::vector binding #436

Open
jorisv opened this issue Feb 5, 2024 · 1 comment
Open

Add non-copyable type support in std::vector binding #436

jorisv opened this issue Feb 5, 2024 · 1 comment
Assignees

Comments

@jorisv
Copy link
Contributor

jorisv commented Feb 5, 2024

There is no way to bind a std::vector with non copyable type (list std::unique_ptr).

@jorisv jorisv self-assigned this Feb 5, 2024
@ManifoldFR
Copy link
Member

ManifoldFR commented May 28, 2024

Coming back to this issue

The problem is with Boost.Python rather limited indexing_suite, which defines __getitem__, etc, methods without allowing the user to inject a return policy:
https://github.com/boostorg/python/blob/0474de0f6cc9c6e7230aeb7164af2f7e4ccf74bf/include/boost/python/suite/indexing/indexing_suite.hpp#L174-L190

What's uncertain right now, is if a subclass of boost::python::indexing_suite can redefine these methods safely at the extension point template<class Class> extension_def(Class &cl) provided by the derived class DerivedPolicies in the CRTP.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants