Preview Ruby 4.1 is a preview. It can change before the final release. Switch to Ruby 4.0 →
instance method
Float#to_f
() -> ::Float
to_f → self
numeric.rb
View on GitHub ↗
# File tmp/rubies/ruby-4.1.0-preview1/numeric.rb, line 360
def to_f
self
end
Returns self (which is already a Float).