Project

General

Profile

This project is closed and read-only.

Actions

Bug #2483

closed

String#to_f of small numbers hangs

Bug #2483: String#to_f of small numbers hangs

Added by mikisvaz (Miguel Vazquez) almost 17 years ago. Updated about 7 years ago.

Status:
Closed
Assignee:
-
ruby -v:
ruby 1.8.7 (2009-06-12 patchlevel 174) [i686-linux]
[ruby-core:27175]

Description

=begin
There is a problem in the String#to_f method. It hangs when the float is really small.

This works:
ruby-1.8 -e 'puts "1e-20".to_f'

This hangs:
ruby-1.8 -e 'puts "1e-100".to_f'
=end

Actions

Also available in: PDF Atom