changeset 605:8dd63473b6d8 rust

config doesn't need Arc
author Matt Johnston <matt@ucc.asn.au>
date Fri, 17 Feb 2017 21:38:36 +0800
parents 278f1002b5c7
children 3c1d37d78415
files rust/src/sensor.rs
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/rust/src/sensor.rs	Thu Feb 16 23:53:46 2017 +0800
+++ b/rust/src/sensor.rs	Fri Feb 17 21:38:36 2017 +0800
@@ -25,13 +25,13 @@
 
 #[derive(Clone)]
 pub struct OneWireSensor {
-    config: Arc<Config>,
+    config: Config,
 }
 
 impl OneWireSensor {
     pub fn new(config: &Config) -> Self {
         OneWireSensor {
-            config: Arc::new(config.clone()),
+            config: config.clone(),
         }
     }