Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
gh-148398: add type watcher in _CHECK_ATTR_CLASS
  • Loading branch information
NekoAsakura committed Apr 11, 2026
commit ca70b69393921bc9abfc8eba8f23a305766bd276
2 changes: 2 additions & 0 deletions Python/optimizer_bytecodes.c
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,8 @@ dummy_func(void) {
}
else {
sym_set_const(owner, type);
PyType_Watch(TYPE_WATCHER_ID, type);
Copy link
Copy Markdown
Contributor

@kumaraditya303 kumaraditya303 Apr 12, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You don't need to add type watcher if type is immutable.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ref #148383

_Py_BloomFilter_Add(dependencies, type);
}
}
}
Expand Down
2 changes: 2 additions & 0 deletions Python/optimizer_cases.c.h

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading