Fix float range behavior
Merge pull request #2959 from simonster/range-fix

Fix float range behavior