[fractal/clippyfixes: 7/7] clippy: using `clone` on a `Copy` type




commit 6b1fe035f8b43a0bc65fdf9420f0c36c385c20a7
Author: Alexandre Franke <afranke gnome org>
Date:   Fri Oct 23 17:56:41 2020 +0200

    clippy: using `clone` on a `Copy` type
    
    https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy

 fractal-gtk/src/actions/global.rs | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/fractal-gtk/src/actions/global.rs b/fractal-gtk/src/actions/global.rs
index 41efc020..dea1fae1 100644
--- a/fractal-gtk/src/actions/global.rs
+++ b/fractal-gtk/src/actions/global.rs
@@ -292,7 +292,7 @@ pub fn new(app: &gtk::Application, op: &Arc<Mutex<AppOp>>) {
                 debug!("Go back to state {:?}", state);
                 if let Some(op) = App::get_op() {
                     let mut op = op.lock().unwrap();
-                    op.set_state(state.clone());
+                    op.set_state(*state);
                 }
             } else {
                 // Fallback when there is no back history


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]