
22 Oct
2011
22 Oct
'11
8:37 a.m.
Personally, I prefer names "round_cast/trunc_cast", as they better describe what's being done. I already use a function "round_to", that does something else:
template < class T > T round_to( const T& x, const T& order ) { return round( x / order ) * order; // By the way, can this be achieved more efficiently? }
I'm not sure if "round_to" is the best name for this, but I think it is not the right name for "round_cast" ;-)
OK, can you file a feature request at svn.boost.org so I don't forget this? Thanks, John.