Hi list,
I'm working on factor's number parsing/printing. I'd like some inputs on
the following problem:

Basically the problem can be seen from this paste:
http://pastebin.com/jxV8UKG2 : setting number-base to 2 or 8 gives
pprint-errors for floats.

So we have the number-base variable in prettyprint.config to chose the
prettyprinter base for numbers. For reals, it supports 2 8 10 and 16. For
floats, only 10 and 16.
Since 99804fd054d5, using an unsupported base throws an exception instead
of defaulting to base 10. What should we do ?
  - go back to the previous behavior: default to base 10 ?
  - add new variables to configure rationals (integers + ratios) and floats
separately?
  - allow floats to be printed in base 2 and 8 ? (for info the parser
supports it: 0b1.1p0 0o1.4p0 0x1.8p0 all parse to 1.5)
  - a mix of the previous ?

What do you think ?
Jon
------------------------------------------------------------------------------
_______________________________________________
Factor-talk mailing list
Factor-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/factor-talk

Reply via email to