
29 Apr
2008
29 Apr
'08
6:33 p.m.
AMDG Paul A Bristow wrote:
T edit_distance(T a, T b)
Returns the number of floating point representations between values a and b.
Definitely useful.
Not convinced by this name, but I'll think about it.
Signed sounds obvious but I suspect choice may be more complicated than it seems.
It's more intuitive to get the unsigned value from the signed than the other way around. std::abs(edit_distance(a, b)) vs. copysign(edit_distance(a, b), b - a) In Christ, Steven Watanabe