Skip to content

Commit 3bdb627

Browse files
committed
core: Make uint::min/max pure
1 parent 910c6a5 commit 3bdb627

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/libcore/uint.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,14 +25,14 @@ const max_value: uint = 0u - 1u;
2525
/*
2626
Function: max
2727
*/
28-
fn max(x: uint, y: uint) -> uint {
28+
pure fn max(x: uint, y: uint) -> uint {
2929
if x > y { x } else { y }
3030
}
3131

3232
/*
3333
Function: min
3434
*/
35-
fn min(x: uint, y: uint) -> uint {
35+
pure fn min(x: uint, y: uint) -> uint {
3636
if x < y { x } else { y }
3737
}
3838

0 commit comments

Comments
 (0)