Remove TrustedWindowHandle#73
Merged
Lokathor merged 2 commits intorust-windowing:masterfrom Nov 19, 2021
Merged
Conversation
Its usefulness is dubious at best
Lokathor
reviewed
Nov 15, 2021
madsmtm
approved these changes
Nov 15, 2021
Comment on lines
+57
to
+75
| unsafe impl<'a, T: HasRawWindowHandle> HasRawWindowHandle for &'a T { | ||
| fn raw_window_handle(&self) -> RawWindowHandle { | ||
| (*self).raw_window_handle() | ||
| } | ||
| } | ||
| unsafe impl<T: HasRawWindowHandle> HasRawWindowHandle for alloc::rc::Rc<T> { | ||
| fn raw_window_handle(&self) -> RawWindowHandle { | ||
| (**self).raw_window_handle() | ||
| } | ||
| } | ||
| unsafe impl<T: HasRawWindowHandle> HasRawWindowHandle for alloc::sync::Arc<T> { | ||
| fn raw_window_handle(&self) -> RawWindowHandle { | ||
| (**self).raw_window_handle() | ||
| } | ||
| } | ||
|
|
Member
There was a problem hiding this comment.
I agree with adding these impls since they are consistent with the current wording of the safety guarantees implementors of HasRawWindowHandle must uphold.
If we find in #71 or likewise that the safety guarantees should change, we can then consider if these impls should change as well.
Member
Author
There was a problem hiding this comment.
Yeah, that's my general reasoning behind pushing this through for now.
5593f6e to
9d0770c
Compare
Member
Author
|
The impls for |
Lokathor
approved these changes
Nov 17, 2021
Contributor
|
This looks good. I'll merge it and publish later today. Publishing as 0.4.1 should be fine, since the averted 0.4.0 was only out for like 20 minutes. |
Contributor
madsmtm
added a commit
to madsmtm/winit
that referenced
this pull request
Nov 19, 2021
madsmtm
added a commit
to madsmtm/winit
that referenced
this pull request
Nov 27, 2021
madsmtm
added a commit
to madsmtm/winit
that referenced
this pull request
Nov 27, 2021
madsmtm
added a commit
to madsmtm/winit
that referenced
this pull request
Nov 27, 2021
msiglreith
pushed a commit
to rust-windowing/winit
that referenced
this pull request
Nov 30, 2021
* Update raw-window-handle to `0.4.2` See: - rust-windowing/raw-window-handle#72 - rust-windowing/raw-window-handle#73 - rust-windowing/raw-window-handle#74 * Clean up raw_window_handle functions a bit
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.
As per @Lokathor's request in #72, I have made some changes that I believe need to be made.
TrustedWindowHandleas its usefulness is somewhat dubious.HasRawWindowHandleas proposed in Improve safety aroundHasRawWindowHandle#71.I believe these impls represent a decent enough usability improvement to be added as-is.
cc @pythonesque
PS: I missed a
0.in the branch name, lol