Resolve a redundant_closure lint warning

This commit is contained in:
Dale Wijnand 2018-08-13 10:40:40 +01:00
parent 6dd73398a3
commit b98fd0e8bd
No known key found for this signature in database
GPG Key ID: 4F256E3D151DF5EF

View File

@ -38,7 +38,7 @@ fn test_lev_distance() {
use std::char::{from_u32, MAX};
// Test bytelength agnosticity
for c in (0u32..MAX as u32)
.filter_map(|i| from_u32(i))
.filter_map(from_u32)
.map(|i| i.to_string())
{
assert_eq!(lev_distance(&c, &c), 0);