Skip to content

Add const to buffer:request() #1890

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

Merged
merged 1 commit into from
Aug 27, 2019
Merged

Add const to buffer:request() #1890

merged 1 commit into from
Aug 27, 2019

Conversation

slarew
Copy link
Contributor

@slarew slarew commented Aug 22, 2019

This PR simply marks buffer::request() as const. Without the const, code cannot have a const py::buffer and request a buffer_info.

request() does not alter the object so it should be conceptually safe.

@wjakob
Copy link
Member

wjakob commented Aug 27, 2019

Looks good, thanks!

@wjakob wjakob merged commit 5b4751a into pybind:master Aug 27, 2019
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.

2 participants