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

Fix clippy::use_self in Xilem Core #747

Merged
merged 3 commits into from
Nov 14, 2024
Merged

Conversation

DJMcNab
Copy link
Member

@DJMcNab DJMcNab commented Nov 13, 2024

All fixes except for removing the expects are results from cargo fix.

@DJMcNab DJMcNab marked this pull request as ready for review November 13, 2024 12:01
@DJMcNab
Copy link
Member Author

DJMcNab commented Nov 13, 2024

(GitHub defaulting to draft PR if your last PR was draft is so annoying...)

@@ -305,7 +305,7 @@ where
ctx: &mut Context,
element: Mut<'_, Self::Element>,
) {
if core::mem::take(&mut view_state.dirty) || !Rc::ptr_eq(self, prev) {
if core::mem::take(&mut view_state.dirty) || !Self::ptr_eq(self, prev) {
Copy link
Member Author

@DJMcNab DJMcNab Nov 13, 2024

Choose a reason for hiding this comment

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

This is probably a downgrade in code quality :(. Do you want me to add an exception?

Copy link
Contributor

Choose a reason for hiding this comment

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

Hmm I don't know, I think it's simple enough such that it should be obvious that it's the pointer equality of the Rc/Arc.

Copy link
Contributor

Choose a reason for hiding this comment

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

But feel free.

@DJMcNab DJMcNab enabled auto-merge November 14, 2024 09:15
@DJMcNab DJMcNab added this pull request to the merge queue Nov 14, 2024
Merged via the queue into linebender:main with commit 628659d Nov 14, 2024
17 checks passed
@DJMcNab DJMcNab deleted the core_use_self branch November 14, 2024 09:25
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.

2 participants