No commit activity in last 3 years
No release in over 3 years
Warn when comparing floats for equality.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
 Dependencies

Development

>= 3.0
 Project Readme

Build Status

x = 1.0 - 0.9 - 0.1
x == 0.0
# WARNING: Testing for equality with inexact floats is ill-advised, when comparing -2.7755575615628914e-17 and 0 (/path/to/file.rb:123)
# => false

Installation and usage

Gemfile:

gem "inexact_equality_warning"
require "inexact_equality_warning"