Fix deprecation warning under Ruby 2.2.0

* Arithmetic#== was not being used, Comparable#== was instead, so it was
  using <=> for comparison but swallowing any exceptions
* Fixes #469
Merge pull request #470 from aripollak/ruby-2.2.0-deprecation-fix

Fix deprecation warning under Ruby 2.2.0