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

Update PyClassGetterGenerator to allow IntoPyObject conversion for Deref::Target #4990

Draft
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

bschoenmaeckers
Copy link
Member

Alternative implementation for #4987 as of comment #4987 (comment).

@@ -70,3 +70,19 @@ probe!(IsSync);
impl<T: Sync> IsSync<T> {
pub const VALUE: bool = true;
}

probe!(IsDerefIntoPyObject);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would like to implement this for T: Deref, for<'a, 'py> &'a T::Target: IntoPyObject<'py> but that will overflow the recursion limit because of the interaction with the Deref implementation of Bound. Is their another way to make this work for user defined wrappers?

@bschoenmaeckers bschoenmaeckers force-pushed the container-specilization branch from b5b0477 to 77b8a47 Compare March 18, 2025 15:37
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

Successfully merging this pull request may close these issues.

1 participant