Sha256: f9dfd1f2489411807b5c188558717784a8f72596aa7f99385370b27bbf0771b8
Contents?: true
Size: 196 Bytes
Versions: 72
Compression:
Stored size: 196 Bytes
Contents
# require "eitil_core/float/safe_to_i" class Float # converts a float to an integer, only when no decimal values are lost. def safe_to_i self == self.to_i ? self.to_i : self end end
Version data entries
72 entries across 72 versions & 1 rubygems