Skip to content

immutable -> hashable in the Glossary#124350

Merged
Eclips4 merged 1 commit into
python:mainfrom
decorator-factory-clones:decorator-factory/glossary-sequence-fix0
Sep 23, 2024
Merged

immutable -> hashable in the Glossary#124350
Eclips4 merged 1 commit into
python:mainfrom
decorator-factory-clones:decorator-factory/glossary-sequence-fix0

Conversation

@decorator-factory

@decorator-factory decorator-factory commented Sep 23, 2024

Copy link
Copy Markdown
Contributor

Dicts accept hashable keys, which is not the same as immutable. For example, user-defined functions are mutable and hashable (so are instances of user-defined classes by default, unless they redefine __eq__ or set __hash__ = None).


📚 Documentation preview 📚: https://cpython-previews--124350.org.readthedocs.build/

@bedevere-app bedevere-app Bot added awaiting review docs Documentation in the Doc dir skip news labels Sep 23, 2024
@Eclips4 Eclips4 added skip issue needs backport to 3.12 only security fixes needs backport to 3.13 bugs and security fixes labels Sep 23, 2024
@Eclips4 Eclips4 self-assigned this Sep 23, 2024

@vstinner vstinner left a comment

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.

LGTM

@Eclips4 Eclips4 left a comment

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.

Thanks!

@Eclips4 Eclips4 enabled auto-merge (squash) September 23, 2024 16:29
@Eclips4 Eclips4 merged commit 6203ef3 into python:main Sep 23, 2024
@miss-islington-app

Copy link
Copy Markdown

Thanks @decorator-factory for the PR, and @Eclips4 for merging it 🌮🎉.. I'm working now to backport this PR to: 3.12, 3.13.
🐍🍒⛏🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Sep 23, 2024
…y of the Glossary (pythonGH-124350)

The term `Immutable` in the `sequence` entry of the glossary is used incorrectly, in fact dicts accepts hashable keys, which is not the same as immutable.
(cherry picked from commit 6203ef3)

Co-authored-by: decorator-factory <42166884+decorator-factory@users.noreply.github.com>
@bedevere-app

bedevere-app Bot commented Sep 23, 2024

Copy link
Copy Markdown

GH-124352 is a backport of this pull request to the 3.13 branch.

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Sep 23, 2024
…y of the Glossary (pythonGH-124350)

The term `Immutable` in the `sequence` entry of the glossary is used incorrectly, in fact dicts accepts hashable keys, which is not the same as immutable.
(cherry picked from commit 6203ef3)

Co-authored-by: decorator-factory <42166884+decorator-factory@users.noreply.github.com>
@bedevere-app bedevere-app Bot removed the needs backport to 3.13 bugs and security fixes label Sep 23, 2024
@bedevere-app

bedevere-app Bot commented Sep 23, 2024

Copy link
Copy Markdown

GH-124353 is a backport of this pull request to the 3.12 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.12 only security fixes label Sep 23, 2024
Eclips4 pushed a commit that referenced this pull request Sep 23, 2024
…e` entry of the Glossary (GH-124350) (#124353)

Replace the term `Immutable` with a `Hashable` in the `sequence` entry of the Glossary (GH-124350)

The term `Immutable` in the `sequence` entry of the glossary is used incorrectly, in fact dicts accepts hashable keys, which is not the same as immutable.
(cherry picked from commit 6203ef3)

Co-authored-by: decorator-factory <42166884+decorator-factory@users.noreply.github.com>
Yhg1s pushed a commit that referenced this pull request Sep 23, 2024
…e` entry of the Glossary (GH-124350) (#124352)

Replace the term `Immutable` with a `Hashable` in the `sequence` entry of the Glossary (GH-124350)

The term `Immutable` in the `sequence` entry of the glossary is used incorrectly, in fact dicts accepts hashable keys, which is not the same as immutable.
(cherry picked from commit 6203ef3)

Co-authored-by: decorator-factory <42166884+decorator-factory@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Documentation in the Doc dir skip issue skip news

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants