Skip to content

gh-155496: Use Argument Clinic for more functions and methods - #158134

Merged
serhiy-storchaka merged 1 commit into
python:mainfrom
serhiy-storchaka:clinic-misc-conversions
Sep 27, 2026
Merged

serhiy-storchaka merged 1 commit into
python:mainfrom
serhiy-storchaka:clinic-misc-conversions

Conversation

@serhiy-storchaka

Copy link
Copy Markdown
Member

Convert the remaining easily convertible functions and methods to Argument Clinic, so that they have a signature for introspection and use a faster calling convention:

  • builtins dir() and vars()
  • property.__set_name__()
  • memoryview.__exit__()
  • structseq __replace__()
  • types.SimpleNamespace.__replace__()
  • re.Match.group()
  • sys.getsizeof() and sys.set_asyncgen_hooks()
  • atexit.register()
  • the os.scandir() iterator __exit__()
  • the _dbm, _gdbm and _decimal context manager __exit__()
  • _functools lru_cache __copy__() and __deepcopy__()
  • _elementtree.SubElement()
  • _interpreters.new_config()
  • _tkinter call() and wantobjects()
  • zoneinfo.ZoneInfo.__init_subclass__()
  • internal hamt and stdprinter methods

Convert to Argument Clinic:

* builtins dir() and vars()
* property.__set_name__()
* memoryview.__exit__()
* structseq __replace__()
* types.SimpleNamespace.__replace__()
* re.Match.group()
* sys.getsizeof() and sys.set_asyncgen_hooks()
* atexit.register()
* os.scandir() iterator __exit__()
* _dbm, _gdbm and _decimal context manager __exit__()
* _functools lru_cache __copy__() and __deepcopy__()
* _elementtree.SubElement()
* _interpreters.new_config()
* _tkinter call() and wantobjects()
* zoneinfo.ZoneInfo.__init_subclass__()
* internal hamt and stdprinter methods
@serhiy-storchaka
serhiy-storchaka merged commit dc59006 into python:main Sep 27, 2026
57 checks passed
@serhiy-storchaka
serhiy-storchaka deleted the clinic-misc-conversions branch September 27, 2026 16:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant