Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Confusion with "immutable" and "hashable" in Design and History FAQ #134114

Closed
Labels
docsDocumentation in the Doc dir
@plusquant

Description

@plusquant

The pagehttps://docs.python.org/3/faq/design.html#why-are-there-separate-tuple-and-list-data-types says at the end of its last paragraph:

Onlyimmutable elements can be used asdictionary keys...

Which is not quite correct, since dictionaries only require its keys to behashable (seehttps://docs.python.org/3/library/stdtypes.html#mapping-types-dict). Immutability doesn't necessarily imply hashability.

Thanks.

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    docsDocumentation in the Doc dir

    Projects

    Status

    Todo

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp