Conversation
via the command `cargo clippy --fix --lib -p xplm`
These should not be breaking changes. There are a couple of warnings I was not certain about, which I've suppressed and marked TODO instead.
mkreu
requested changes
May 4, 2025
Comment on lines
+102
to
104
| // TODO: examine if this warning is applicable and this should be `to_xplm(self)` | ||
| #[allow(clippy::wrong_self_convention)] | ||
| fn to_xplm(&self) -> xplm_sys::XPLMDrawingPhase { |
Owner
There was a problem hiding this comment.
Probably this should be renamed to as_xplm
Comment on lines
97
to
+98
| /// Each item is in a Box, to allow callbacks to reference it. | ||
| children: RefCell<Vec<Box<Item>>>, | ||
| children: RefCell<Vec<Item>>, |
Owner
There was a problem hiding this comment.
The comment above this line indicates that there was a reason for this additional boxing, although I do not entirely get what this comment wants to tell me...
Comment on lines
+93
to
95
| // TODO: determine if Clippy warning about `new` not returning `self` is applicable | ||
| #[allow(clippy::new_ret_no_self)] | ||
| pub fn new<R: Into<Rect<i32>>, D: WindowDelegate>(geometry: R, delegate: D) -> WindowRef { |
Owner
There was a problem hiding this comment.
we should probably rename this function to create(...) or sth. similar
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
There are 30 Clippy warnings, 21 of which can be automatically fixed. This PR suppresses three of them and resolves the others.