)]}'
{
  "commit": "83f71d8b82e9bf1360cfc926afd70c40412f469d",
  "tree": "24cb19c72d09119368d1ce1c9fa9002f506078e3",
  "parents": [
    "524d72b36dad6ece7e389b709d5081976de42630"
  ],
  "author": {
    "name": "Ralf W. Grosse-Kunstleve",
    "email": "rwgkio@gmail.com",
    "time": "Mon Mar 30 10:49:27 2026 +0700"
  },
  "committer": {
    "name": "GitHub",
    "email": "noreply@github.com",
    "time": "Sun Mar 29 20:49:27 2026 -0700"
  },
  "message": "fix: detect virtual inheritance in add_base to prevent pointer offset crash (#6017)\n\nVirtual inheritance places the base subobject at a dynamic offset, but\nload_impl Case 2a uses reinterpret_cast which assumes a fixed offset.\nThis caused segfaults when dispatching inherited methods through virtual\nbases (e.g. SftVirtDerived2::name()).\n\nAdd an is_static_downcastable SFINAE trait that detects whether\nstatic_cast\u003cDerived*\u003e(Base*) is valid. When it is not (virtual\ninheritance), set multiple_inheritance \u003d true in add_base to force the\nimplicit_casts path, which correctly adjusts pointers at runtime.\n\nRemove the workaround .def(\"name\", \u0026SftVirtDerived2::name) from\ntest_smart_ptr.cpp that was papering over the issue.\n\nMade-with: Cursor",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "ae682f308f99769947299c70d087b987782636df",
      "old_mode": 33188,
      "old_path": "include/pybind11/detail/common.h",
      "new_id": "7dc278ea277635f5cd4f9820c49a252e336df077",
      "new_mode": 33188,
      "new_path": "include/pybind11/detail/common.h"
    },
    {
      "type": "modify",
      "old_id": "f5cf411c6401cac2f4099955daa1d652a60fe93d",
      "old_mode": 33188,
      "old_path": "include/pybind11/pybind11.h",
      "new_id": "12c0cd65a2c1a830cd655ab4f63c269b832d187b",
      "new_mode": 33188,
      "new_path": "include/pybind11/pybind11.h"
    },
    {
      "type": "modify",
      "old_id": "f5036eac382139794424e91f7d3c95a48a7fa052",
      "old_mode": 33188,
      "old_path": "tests/test_smart_ptr.cpp",
      "new_id": "3617fa3e8518f783d349e416c0c15a0bbd8d1875",
      "new_mode": 33188,
      "new_path": "tests/test_smart_ptr.cpp"
    }
  ]
}
