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

Update to 2021 edition #236

Merged
merged 4 commits into from
Nov 4, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .changes/edition.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"tao": patch
---

Update to 2021 edition and msrv to 1.56

3 changes: 2 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@ authors = [
"Tauri Programme within The Commons Conservancy",
"The winit contributors"
]
edition = "2018"
edition = "2021"
rust-version = "1.56"
keywords = [ "windowing" ]
license = "Apache-2.0"
readme = "README.md"
Expand Down
1 change: 1 addition & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,7 @@
//! [`platform`]: platform
//! [`raw_window_handle`]: ./window/struct.Window.html#method.raw_window_handle
#![allow(
clippy::match_str_case_mismatch,
clippy::upper_case_acronyms,
clippy::from_over_into,
clippy::option_map_unit_fn,
Expand Down
5 changes: 4 additions & 1 deletion src/platform_impl/macos/observer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,10 @@ where
// However we want to keep that weak reference around after the function.
std::mem::forget(info_from_raw);

stop_app_on_panic(Weak::clone(&panic_info), move || f(panic_info.0));
stop_app_on_panic(Weak::clone(&panic_info), move || {
let _ = &panic_info;
f(panic_info.0)
});
}

// begin is queued with the highest priority to ensure it is processed before other observers
Expand Down