Fix some warnings here and there, remove unwelcomed code
authorunC0Rr
Wed, 07 Nov 2018 15:55:00 +0100
changeset 14173 5acfdf49742d
parent 14172 3c8a33ba06ba
child 14174 b273b43b16d2
Fix some warnings here and there, remove unwelcomed code
rust/integral-geometry/src/lib.rs
rust/land_dump/src/main.rs
rust/lfprng/src/lib.rs
--- a/rust/integral-geometry/src/lib.rs	Wed Nov 07 03:35:56 2018 +0300
+++ b/rust/integral-geometry/src/lib.rs	Wed Nov 07 15:55:00 2018 +0100
@@ -505,7 +505,6 @@
     }
 
     pub fn iter_mut<'a>(&'a mut self) -> impl Iterator<Item = &mut Point> + 'a {
-        let edges_count = self.edges_count();
         let start = self.vertices.as_mut_ptr();
         let end = unsafe { start.add(self.vertices.len()) };
         PolygonPointsIteratorMut {
--- a/rust/land_dump/src/main.rs	Wed Nov 07 03:35:56 2018 +0300
+++ b/rust/land_dump/src/main.rs	Wed Nov 07 15:55:00 2018 +0100
@@ -86,12 +86,7 @@
 
             let mut generator = MapGenerator::new();
 
-            let bom = b"\xEF\xBB\xBF";
-            let source = if &result.as_bytes()[..bom.len()] == &bom[..] {
-                &result[bom.len()..]
-            } else {
-                &result[..]
-            };
+            let source =  &result[..];
 
             generator.import_yaml_templates(source);
 
--- a/rust/lfprng/src/lib.rs	Wed Nov 07 03:35:56 2018 +0300
+++ b/rust/lfprng/src/lib.rs	Wed Nov 07 15:55:00 2018 +0100
@@ -16,7 +16,7 @@
             index: 54,
         };
 
-        for i in 0..2048 {
+        for _i in 0..2048 {
             prng.get_next();
         }