Skip to content

Add const to buffer:request()#1890

Merged
wjakob merged 1 commit into
pybind:masterfrom
slarew:requestconst
Aug 27, 2019
Merged

Add const to buffer:request()#1890
wjakob merged 1 commit into
pybind:masterfrom
slarew:requestconst

Conversation

@slarew

@slarew slarew commented Aug 22, 2019

Copy link
Copy Markdown
Contributor

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

wjakob commented Aug 27, 2019

Copy link
Copy Markdown
Member

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