Skip to content

Fix clippy multiple_bound_location warnings#528

Merged
bors merged 3 commits intorust-lang:masterfrom
ToMe25:clippy_fixes
May 30, 2024
Merged

Fix clippy multiple_bound_location warnings#528
bors merged 3 commits intorust-lang:masterfrom
ToMe25:clippy_fixes

Conversation

@ToMe25
Copy link
Contributor

@ToMe25 ToMe25 commented May 30, 2024

This PR moves the ?Sized generics bound used in the map and set source files from the generics predicate to the where clause, if a where clause already exists.

According to what I could find online that ?Sized bound had to be there until rustc 1.15, but since ?Sized is already specified in where clauses in these files I don't think thats an issue.

I always put the ?Sized bound last, because that is where it already appears in the docs, but if ?Sized first is preferred, I'll change that.

This PR also changes the Debug impls for *EntryRef to use a where clause, because they currently have a linebreak in "impl X for Y" line.
If this last change isn't wanted or considered something separate, please let me know :)

@Amanieu
Copy link
Member

Amanieu commented May 30, 2024

Thanks!

@bors r+

@bors
Copy link
Contributor

bors commented May 30, 2024

📌 Commit 1c8b695 has been approved by Amanieu

It is now in the queue for this repository.

@bors
Copy link
Contributor

bors commented May 30, 2024

⌛ Testing commit 1c8b695 with merge f540cb7...

@bors
Copy link
Contributor

bors commented May 30, 2024

☀️ Test successful - checks-actions
Approved by: Amanieu
Pushing f540cb7 to master...

@bors bors merged commit f540cb7 into rust-lang:master May 30, 2024
@ToMe25 ToMe25 deleted the clippy_fixes branch June 4, 2024 09:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants