chore: address 1.79 clippy lints
This commit is contained in:
parent
3b4e064a07
commit
078b46720b
15 changed files with 30 additions and 30 deletions
|
|
@ -42,7 +42,11 @@ impl<T> EventLoop<T> {
|
|||
// SAFETY: The `transmute` is necessary because `run()` requires `'static`. This is safe
|
||||
// because this function will never return and all resources not cleaned up by the point we
|
||||
// `throw` will leak, making this actually `'static`.
|
||||
let handler = unsafe { std::mem::transmute(handler) };
|
||||
let handler = unsafe {
|
||||
std::mem::transmute::<Box<dyn FnMut(Event<()>)>, Box<dyn FnMut(Event<()>) + 'static>>(
|
||||
handler,
|
||||
)
|
||||
};
|
||||
self.elw.p.run(handler, false);
|
||||
|
||||
// Throw an exception to break out of Rust execution and use unreachable to tell the
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue