Skip to content

Commit 8773c29

Browse files
authored
nucleotide-codons: rm unneeded return (#1003)
clippy: warning: unneeded `return` statement note: `#[warn(clippy::needless_return)]` on by default help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return Removing the `return` and semicolon will make the code more rusty. I understand this exercise is deprecated and that we already did this to protein-translation in 3d3cd9a. Clippy doesn't know this when we run it against all the exercises, so might as well just do this to get closer to zero Clippy warnings in tests (which we are pretty close to)
1 parent fc7e538 commit 8773c29

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

exercises/nucleotide-codons/tests/codons.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,5 +111,5 @@ fn make_pairs() -> Vec<(&'static str, &'static str)> {
111111
}
112112
}
113113
pairs.sort_by(|&(_, a), &(_, b)| a.cmp(b));
114-
return pairs;
114+
pairs
115115
}

0 commit comments

Comments
 (0)