Arithmetic/Rational: Difference between revisions

Added constructor in the D entry
(Small improvements in the D entry)
(Added constructor in the D entry)
Line 522:
return Type.NaRAT;
}
}
 
RationalT!U rational(U)(in U n) pure /*nothrow*/ {
return typeof(return)(n);
}
 
RationalT!(CommonType!(U1, U2))
rational(U1, U2)(in U1 n, in U2 d) pure /*nothrow*/ {
return typeof(return)(n, d);
}