Skip to content

Commit 5038d4e

Browse files
committed
std::cmp::max -> max
1 parent 6c8dd52 commit 5038d4e

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/librustc_driver/lib.rs

+6-6
Original file line numberDiff line numberDiff line change
@@ -628,12 +628,12 @@ Available lint options:
628628

629629

630630

631-
let max_name_len = plugin_groups.iter()
632-
.chain(&builtin_groups)
633-
.map(|&(s, _)| s.chars().count())
634-
.max()
635-
.unwrap_or(0);
636-
let max_name_len = std::cmp::max(max_name_len, "warnings".len());
631+
let max_name_len = max("warnings".len(),
632+
plugin_groups.iter()
633+
.chain(&builtin_groups)
634+
.map(|&(s, _)| s.chars().count())
635+
.max()
636+
.unwrap_or(0));
637637

638638
let padded = |x: &str| {
639639
let mut s = repeat(" ")

0 commit comments

Comments
 (0)