)]}'
{
  "commit": "012665968f770ce3d6a082100f14a09686e407e9",
  "tree": "fff5f1c288813f22ac7b2303b6ec6ca14dcd70c3",
  "parents": [
    "fe3033206fb4cf636ce38f85b3c72172dc222e83"
  ],
  "author": {
    "name": "Sam Clegg",
    "email": "sbc@chromium.org",
    "time": "Tue Nov 17 17:42:48 2026"
  },
  "committer": {
    "name": "Sam Clegg",
    "email": "sbc@chromium.org",
    "time": "Tue Nov 17 17:43:13 2026"
  },
  "message": "[jsifier] Share (and fix) function-matching regexes\n\nExtract shared module-level `arrowFuncRe` and `regularFuncRe` regexes in\n`src/jsifier.mjs` and use both for stringified function detection and\nmangled name emission.\n\nPreviously:\n- Both arrow regexes used `[^}]*`, failing on destructured parameters\n  (e.g. `({a}) \u003d\u003e ...`), omitting single-arg (including `$` and `async`\n  as a parameter) and `async` arrow forms (including `async(x) \u003d\u003e ...`),\n  and potentially misclassifying regular functions with default arrow\n  parameters.\n- Stringified `function` detection (`/^function\\b/`) did not allow\n  leading whitespace or `async`, and did not share the regular-function\n  name-replacement regex (`regularFuncRe`), which now anchors at `^`,\n  requires `(`, and preserves leading whitespace and `async`.\n- Stringified function detection lacked a `!isConst` guard, risking\n  treating `__const` string literals like `x \u003d\u003e ...` or `function(...)`\n  as functions.\n\nAdd `test_jslib_function_forms` in `test/test_jslib.py` covering these\ncases.\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "6477b6841c9db63a8319b27258811c512a7e9714",
      "old_mode": 33188,
      "old_path": "src/jsifier.mjs",
      "new_id": "381ac42dde816505260de2999c1eb25888876443",
      "new_mode": 33188,
      "new_path": "src/jsifier.mjs"
    },
    {
      "type": "modify",
      "old_id": "5bc2759718d09c5915404aba99034e8d3fafc285",
      "old_mode": 33188,
      "old_path": "test/test_jslib.py",
      "new_id": "abc46e49a88772f64be07584e1a7e8a85d2e2f62",
      "new_mode": 33188,
      "new_path": "test/test_jslib.py"
    }
  ]
}
