diff options
author | Igor Pashev <pashev.igor@gmail.com> | 2019-10-06 10:01:18 +0200 |
---|---|---|
committer | Igor Pashev <pashev.igor@gmail.com> | 2019-10-06 10:01:18 +0200 |
commit | 5e50fa946f5ea89f1cbfcc3db8b232565f6a61f2 (patch) | |
tree | 4d8991efb8f0ca3b38e51df88d44c47150933826 | |
parent | a65f7591894f67021df3490c07ab7e75627e476e (diff) | |
download | frotate.rs-5e50fa946f5ea89f1cbfcc3db8b232565f6a61f2.tar.gz |
With no return
-rw-r--r-- | src/lib.rs | 4 | ||||
-rw-r--r-- | src/main.rs | 2 |
2 files changed, 3 insertions, 3 deletions
@@ -22,7 +22,7 @@ pub fn partition (f: &Fn(u32) -> i64, v: &Vec<i64>) -> LinkedList<LinkedList<i64 } res.push_back(term); - return res; + res } pub fn partition_days (f: &Fn(u32) -> i64, days: &Vec<NaiveDate>) -> LinkedList<LinkedList<NaiveDate>> { @@ -46,5 +46,5 @@ pub fn partition_days (f: &Fn(u32) -> i64, days: &Vec<NaiveDate>) -> LinkedList< |d| day1 - Duration::days(d)).rev().collect() ).collect(); - return res + res } diff --git a/src/main.rs b/src/main.rs index ba7b145..8bf737a 100644 --- a/src/main.rs +++ b/src/main.rs @@ -32,7 +32,7 @@ struct Args { fn exponent(b:f32, n:u32) -> i64 { let i : i32 = n as i32 - 1; - return b.powi(i).ceil() as i64; + b.powi(i).ceil() as i64 } fn main() { |