Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove outdated comment about std::hash::DefaultHasher being inaccessible #135735

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

dbdr
Copy link

@dbdr dbdr commented Jan 19, 2025

Fixes #134717 (confirmed by @hkBst)

@rustbot
Copy link
Collaborator

rustbot commented Jan 19, 2025

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @ibraheemdev (or someone else) some time within the next two weeks.

Please see the contribution instructions for more information. Namely, in order to ensure the minimum review times lag, PR authors and assigned reviewers should ensure that the review label (S-waiting-on-review and S-waiting-on-author) stays updated, invoking these commands when appropriate:

  • @rustbot author: the review is finished, PR author should check the comments and take action accordingly
  • @rustbot review: the author is ready for a review, this PR will be queued again in the reviewer's queue

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Jan 19, 2025
@@ -2,9 +2,6 @@
//! [`collections`] module without actually publicly exporting them, so that parts of that
//! implementation can more easily be moved to the [`alloc`] crate.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like this comment is outdated too.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You are right. So should this entire module be unmoduled and inlined into another file?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment on lines -5 to -7
//! Although its items are public and contain stability attributes, they can't actually be accessed
//! outside this crate.
//!
Copy link
Member

@ibraheemdev ibraheemdev Jan 31, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Taking a closer look, I think the comments are actually correct. This module was added in #115694 for the reasons the comment mentions. I think we can confusion by mentioning that the types are re-exported elsewhere.

- //! Although its items are public and contain stability attributes, they can't actually be accessed
- //! outside this crate.
+ //! Although its items are public and contain stability attributes, they can't actually be accessed
+ //! through this module, and are instead re-exported from `std::hash` and `std::collections::hash_map`.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I still think this comment is more confusing than enlightening, and best removed. It's a crate-private module with exports through https://github.com/rust-lang/rust/blob/master/library/std/src/hash/mod.rs.

@ibraheemdev ibraheemdev added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jan 31, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. T-libs Relevant to the library team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Outdated comment about std::hash::DefaultHasher being inaccessible
4 participants