Skip to content

Commit

Permalink
auto merge of #16233 : omasanori/rust/abs_sub, r=steveklabnik
Browse files Browse the repository at this point in the history
Use proper argument names and unbackquote the word "zero" because it is not an identifier.
  • Loading branch information
bors committed Aug 4, 2014
2 parents d3ac386 + 3e6edee commit 765a23f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/libcore/num/mod.rs
Expand Up @@ -279,8 +279,8 @@ pub fn abs<T: Signed>(value: T) -> T {

/// The positive difference of two numbers.
///
/// Returns `zero` if the number is less than or equal to `other`,
/// otherwise the difference between `self` and `other` is returned.
/// Returns zero if `x` is less than or equal to `y`, otherwise the difference
/// between `x` and `y` is returned.
#[inline(always)]
pub fn abs_sub<T: Signed>(x: T, y: T) -> T {
x.abs_sub(&y)
Expand Down

0 comments on commit 765a23f

Please sign in to comment.