Avoid exact floating-point comparison

Fixes #77