[Python-Dev] Proposal: dict.with_values(iterable) (original) (raw)
Inada Naoki songofacandy at gmail.com
Tue Apr 23 00:43:07 EDT 2019
- Previous message (by thread): [Python-Dev] Proposal: dict.with_values(iterable)
- Next message (by thread): [Python-Dev] Proposal: dict.with_values(iterable)
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Tue, Apr 23, 2019 at 11:30 AM Steve Dower <steve.dower at python.org> wrote:
Or possibly just "dict(existingdict).update(newitems)".
Do you mean .update accepts values tuple? I can't think it's
My primary concern is still to avoid making CPython performance characteristics part of the Python language definition. That only makes it harder for alternate implementations.
Note that this proposal is not only for key sharing dict:
- We can avoid rebuilding hash table again and again.
- We can avoid checking duplicated keys again and again.
These characteristics are not only for Python, but for all mapping implementations using hash table.
-- Inada Naoki <songofacandy at gmail.com>
- Previous message (by thread): [Python-Dev] Proposal: dict.with_values(iterable)
- Next message (by thread): [Python-Dev] Proposal: dict.with_values(iterable)
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]