← Winnitude! Search  ·  Reader Mode (1603 ms)
Links: Stay in Reader Retro Site Converter Retro Mode: OFF Original Page ↗
GITHUB · 13 LINKS

Improve performance of keyword arguments collected by **kwargs · Issue #163213 · python/cpython

Repository navigation

Improve performance of keyword arguments collected by **kwargs  #163213


New issue

New issue

Backlog

Backlog
Improve performance of keyword arguments collected by **kwargs #163213 Labels
interpreter-core

performance

type-feature

Description

@eendebakpt's profile eendebakpt opened on Dec 5, 2026

Feature or enhancement

A keyword that does not name a parameter is first looked up among the parameter names by identity and then, as a fallback, compared with each of them by value before it goes into **kwargs. Parameter names are always interned (intern_strings() in _PyCode_New()), so an interned keyword that was not found by identity cannot match, and the fallback loop can be skipped. Keywords that are not interned, including instances of str subclasses, are compared as before.

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels


    interpreter-core

    performance

    type-feature

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions