mirror of
https://github.com/emilk/egui.git
synced 2026-08-30 13:20:05 -04:00
Remove the as_any fns
This commit is contained in:
@@ -71,12 +71,6 @@ impl<S> Plugin<S> for CountingPlugin {
|
||||
TestResult::Fail { .. } => "on_test_result:fail",
|
||||
});
|
||||
}
|
||||
fn as_any(&self) -> &dyn std::any::Any {
|
||||
self
|
||||
}
|
||||
fn as_any_mut(&mut self) -> &mut dyn std::any::Any {
|
||||
self
|
||||
}
|
||||
}
|
||||
|
||||
/// Lifecycle ordering: a simple run+drop cycle fires the expected hooks in order.
|
||||
@@ -141,12 +135,6 @@ fn advance_frame_skips_hooks() {
|
||||
h.advance_frame();
|
||||
}
|
||||
}
|
||||
fn as_any(&self) -> &dyn std::any::Any {
|
||||
self
|
||||
}
|
||||
fn as_any_mut(&mut self) -> &mut dyn std::any::Any {
|
||||
self
|
||||
}
|
||||
}
|
||||
|
||||
let log: Log = Arc::default();
|
||||
@@ -188,12 +176,6 @@ fn mid_dispatch_registration_is_deferred() {
|
||||
h.add_plugin(latecomer);
|
||||
}
|
||||
}
|
||||
fn as_any(&self) -> &dyn std::any::Any {
|
||||
self
|
||||
}
|
||||
fn as_any_mut(&mut self) -> &mut dyn std::any::Any {
|
||||
self
|
||||
}
|
||||
}
|
||||
|
||||
let log: Log = Arc::default();
|
||||
@@ -263,12 +245,6 @@ fn reentrant_step_panics_in_debug() {
|
||||
// Forbidden: step from inside a hook.
|
||||
h.step();
|
||||
}
|
||||
fn as_any(&self) -> &dyn std::any::Any {
|
||||
self
|
||||
}
|
||||
fn as_any_mut(&mut self) -> &mut dyn std::any::Any {
|
||||
self
|
||||
}
|
||||
}
|
||||
|
||||
let mut harness = Harness::builder().with_plugin(Misbehaver).build_ui(|ui| {
|
||||
|
||||
Reference in New Issue
Block a user