Skip to content

Commit

Permalink
Merge branch 'pybind:master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
sun1638650145 authored Sep 16, 2024
2 parents 8ee9e49 + a7910be commit befdee9
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions include/pybind11/pybind11.h
Original file line number Diff line number Diff line change
Expand Up @@ -1382,7 +1382,17 @@ class generic_type : public object {
} else {
internals.registered_types_cpp[tindex] = tinfo;
}

PYBIND11_WARNING_PUSH
#if defined(__GNUC__) && __GNUC__ == 12
// When using GCC 12 these warnings are disabled as they trigger
// false positive warnings. Discussed here:
// https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115824.
PYBIND11_WARNING_DISABLE_GCC("-Warray-bounds")
PYBIND11_WARNING_DISABLE_GCC("-Wstringop-overread")
#endif
internals.registered_types_py[(PyTypeObject *) m_ptr] = {tinfo};
PYBIND11_WARNING_POP
});

if (rec.bases.size() > 1 || rec.multiple_inheritance) {
Expand Down

0 comments on commit befdee9

Please sign in to comment.