From: Gavin Sinclair Date: 2012-01-24T09:53:25+09:00 Subject: Re: Microrant on Ruy's Math Skills On Tue, Jan 24, 2012 at 10:19 AM, Ryan Davis wrote: > > Ruby is pretty dynamic.  It seems entirely reasonable to consider whether > > Float could be redefined to dispatch to BigDecimal except when called > > explicitly, for instance. > > Except for that whole "parse time is different from run time" part you > seem to be blithely ignoring. If you've already parsed float literals, then > they're floats and are already lossy. Unless the parser stores a string representation in addition to the float itself. Then at runtime, the string rep could be used to instantiate a BigDecimal if that runtime option has been activated. Of course, I'm NOT advocating this!