Skip to content
Snippets Groups Projects
Commit 6cd3c0d5 authored by jcarpent's avatar jcarpent
Browse files

[Memory] Remove useless warning

parent 37f9b3b2
No related branches found
No related tags found
No related merge requests found
...@@ -79,7 +79,7 @@ namespace boost { namespace python { namespace objects { \ ...@@ -79,7 +79,7 @@ namespace boost { namespace python { namespace objects { \
\ \
Py_ssize_t holder_offset = reinterpret_cast<Py_ssize_t>(holder) \ Py_ssize_t holder_offset = reinterpret_cast<Py_ssize_t>(holder) \
- reinterpret_cast<Py_ssize_t>(&instance->storage) \ - reinterpret_cast<Py_ssize_t>(&instance->storage) \
+ offsetof(instance_t, storage); \ + static_cast<Py_ssize_t>(offsetof(instance_t, storage)); \
Py_SIZE(instance) = holder_offset; \ Py_SIZE(instance) = holder_offset; \
\ \
protect.cancel(); \ protect.cancel(); \
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment