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

nb::typed<>: support use in return position #174

Merged
merged 1 commit into from Apr 5, 2023

Conversation

oremanj
Copy link
Contributor

@oremanj oremanj commented Apr 5, 2023

The uses are analogous to those in argument position; for example, you might want to return nb::iterator but indicate in the signature that it's an iterator over some specific type. It almost worked already, just had a typo in the type_caster.

The uses are analogous to those in argument position; for example, you might want to return `nb::iterator` but indicate in the signature that it's an iterator over some specific type. It almost worked already, just had a typo in the `type_caster`.
@wjakob
Copy link
Owner

wjakob commented Apr 5, 2023

Great catch, but what is the documentation change about?

@oremanj
Copy link
Contributor Author

oremanj commented Apr 5, 2023

The doc change is just "function argument" -> "function argument or return value".

@wjakob
Copy link
Owner

wjakob commented Apr 5, 2023

Got it. (It looked identical after a superficial check). Thanks!

@wjakob wjakob merged commit d047790 into wjakob:master Apr 5, 2023
16 checks passed
wjakob pushed a commit that referenced this pull request Apr 5, 2023
The uses are analogous to those in argument position; for example, you might want to return `nb::iterator` but indicate in the signature that it's an iterator over some specific type. It almost worked already, just had a typo in the `type_caster`.
@oremanj oremanj deleted the cast-typed branch May 1, 2023 00:29
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.

None yet

2 participants