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 build warnings on Rust 1.37+ #88

Merged
merged 3 commits into from Aug 5, 2020

Conversation

xobs
Copy link
Contributor

@xobs xobs commented Apr 7, 2020

This patchset fixes build warnings that were encountered when using Rust 1.42.0. These most likely exist on any Rust version since 1.37.

Note that this bumps the MSRV up to at least 1.36, since that's when mem::MaybeUninit was introduced.

xobs added 3 commits April 7, 2020 09:39
The `mem::uninitialized()` function is considered undefined behavior,
and is therefore heavily deprecated.  Instead, `mem::MaybeUninit` is
preferred.

Convert the usage of `mem::uninitialized()` into `mem::MaybeUninit` in
the `Transform::identity()` function to remove this UB.

Signed-off-by: Sean Cross <sean@xobs.io>
The constant ATOMIC_BOOL_INIT was deprecated when const fn support was
added, because `AtomicBool::new()` can now be used.  Replace this
constant with the function call in order to remove a deprecated warning.

Signed-off-by: Sean Cross <sean@xobs.io>
As of Rust 1.37, trait objects without the `dyn` marker will produce
warnings.  This results in many warnings when building `iui`.

Annotate all trait objects with this dyn marker.

Signed-off-by: Sean Cross <sean@xobs.io>
@NoraCodes NoraCodes merged commit 6717cbc into rust-native-ui:master Aug 5, 2020
@NoraCodes NoraCodes added k-buildprocess Issues with building the crate p-high High Priority p-medium Medium Priority and removed p-high High Priority labels Aug 5, 2020
@NoraCodes NoraCodes added this to the 0.4 Release milestone Aug 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
k-buildprocess Issues with building the crate p-medium Medium Priority
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants