Method: String#to_Float

Defined in:
lib/y_support/core_ext/string/misc.rb

#to_FloatObject

Float() style conversion, or false if conversion impossible.



19
20
21
22
23
24
25
26
# File 'lib/y_support/core_ext/string/misc.rb', line 19

def to_Float
  begin
    fl = Float stripn
    return fl
  rescue ArgumentError
    return false
  end
end