auto merge of #5994 : huonw/rust/rational-fail-message, r=thestinger
A pedantic correction; the quotient is the result of `a/b`, not `b`.
This commit is contained in:
commit
0de3e7a23c
1 changed files with 1 additions and 1 deletions
|
|
@ -51,7 +51,7 @@ impl<T: Copy + Num + Ord>
|
|||
#[inline(always)]
|
||||
pub fn new(numer: T, denom: T) -> Ratio<T> {
|
||||
if denom == Zero::zero() {
|
||||
fail!(~"quotient of 0");
|
||||
fail!(~"denominator == 0");
|
||||
}
|
||||
let mut ret = Ratio::new_raw(numer, denom);
|
||||
ret.reduce();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue