On Sun, Apr 24, 2011 at 6:13 PM, Steven D'Aprano <steve+comp.lang.pyt...@pearwood.info> wrote: > suppose an implementation might choose to trade off memory for time, > skipping string -> bignum conversations at the cost of doubling the > memory requirements. But even if I grant you bignums, you have to do the > same for floats. Re-implementing the entire floating point library is not > a trivial task, especially if you want to support arbitrary precision > floats.
Or just arbitrary precision decimal strings, which aren't "floats" at all. But to be honest, I've never looked at any implementation of REXX (and the open source implementations do seem to be inferior to IBM's OS/2 implementation, I think - haven't done any empirical testing though), so I can't say how it's done. But it seems to my small understanding that it'd be simpler to just work with the base 10 string than to convert it to base 256 or base 2**32 or something, just because you skip the conversions. Obviously this makes REXX a poor choice for heavy HEAVY computation, but it's potentially faster for things that involve a little computation and a lot of string manipulation (which is where REXX does well). Chris Angelico -- http://mail.python.org/mailman/listinfo/python-list