On Friday, 10 October 2014 04:12:37 UTC+1, David P. Sanders wrote: > > I believe (but please correct me if I'm wrong) that I do need a macro, > since I use it with whole expressions to ensure the correct rounding, for > example > (simplifying) something like > > @round_down( min(a*b, c*d) ) >
You can use with_rounding for this:
with_rounding(() -> min(a*b,c*d), T, RoundDown)
or equivalently, with do syntax:
with_rounding(T, RoundDown) do
min(a*b,c*d)
end
-Simon
