)]}'
{
  "commit": "1a2cbf71e6d8003e5254b7f03894228874dbc166",
  "tree": "3096539e626f7f6bf287749a5b91f549b7b01f86",
  "parents": [
    "c71c85bcc8084d1fcc526aad2019c2597f31cab1"
  ],
  "author": {
    "name": "Jukka Lehtosalo",
    "email": "jukka.lehtosalo@iki.fi",
    "time": "Thu Nov 19 16:33:25 2026 +0000"
  },
  "committer": {
    "name": "GitHub",
    "email": "noreply@github.com",
    "time": "Thu Nov 19 16:33:25 2026 +0000"
  },
  "message": "[mypyc] Fix bad C for attribute names that are C keywords when mangled (#22526)\n\nFixes mypyc/mypyc#1217. Fixes mypyc/mypyc#1187.\n\nThe C struct field name of a native attribute is the attribute name with\na \"_\" prefix, which can produce a C keyword or some other name reserved\nby C compilers, resulting in confusing C compilation errors:\n\n```python\nclass C:\n    def __init__(self) -\u003e None:\n        self._restrict \u003d 0  # Field \"__restrict\" is a keyword in gcc/clang\n```\n\nMany names names were affected.\n\nNow if the prefixed name is reserved by the C standard (it starts with\ntwo underscores or an underscore followed by an uppercase letter) or is\na known MSVC keyword, an additional \"m\" prefix is used. This can\u0027t\ncollide with other field names, since they all start with \"_\".",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "c018307d56450194410a26e88048eb7871762d67",
      "old_mode": 33188,
      "old_path": "mypyc/codegen/emit.py",
      "new_id": "4ab9b772b15e1c8f287eae8cc5c296aca26c32e7",
      "new_mode": 33188,
      "new_path": "mypyc/codegen/emit.py"
    },
    {
      "type": "modify",
      "old_id": "ee562eeff3d99dbab2b36d3a7c65430018c1080b",
      "old_mode": 33188,
      "old_path": "mypyc/test-data/run-classes.test",
      "new_id": "1304837c9925572149b5fb2929f91c5894d2ed58",
      "new_mode": 33188,
      "new_path": "mypyc/test-data/run-classes.test"
    }
  ]
}
