Skip to content

Commit 6a12a29

Browse files
senekorpetertseng
authored andcommitted
poker: elide needless explicit lifetimes
https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes The additional lifetimes make the code look more complicated, while there is nothing out of the ordinary going on. Removing them leads to more readable code.
1 parent e3774aa commit 6a12a29

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

exercises/practice/poker/tests/poker.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ fn hs_from<'a>(input: &[&'a str]) -> HashSet<&'a str> {
1414
///
1515
/// Note that the output can be in any order. Here, we use a HashSet to
1616
/// abstract away the order of outputs.
17-
fn test<'a, 'b>(input: &[&'a str], expected: &[&'b str]) {
17+
fn test(input: &[&str], expected: &[&str]) {
1818
assert_eq!(hs_from(&winning_hands(input)), hs_from(expected))
1919
}
2020

0 commit comments

Comments
 (0)