On 10/02/2016 15:41, Anthony Fox wrote:
This is significant change. Would it be possible to make this user selectable? MLton has the command line flag
-default-type intinf
when IntInf is preferred for Int.
Perhaps there could be a switch to "configure". It's really a question of how the basis library is built.
I had been programming on the basis that Int was arbitrary precision in Poly/ML. I certainly need IntInf in places and it was very convenient to not have to worry about this sort of thing. Having to use ?to? and ?from? functions is a nuisance. I?ve attempted to update my code for this change and the diff was
19 files changed, 334 insertions(+), 275 deletions(-)
In itself this wasn?t too bad. However, after this I have less confidence in the robustness of the code. Poly/ML programmer?s have not needed to insert ?handle Overflow? before now, which is great advantage over ?performance obsessed? compilers.
Anyhow, HOL4 doesn?t build using the FixedPrecisionInt branch. An early problem was due to Position.int no longer being the same as Int.int. Then I got a
Segmentation fault: 11
error when trying to build a parser. This problem may be related to
Bus error: 10
errors that I?ve been getting. For example, if I use polyc to compile
val main = PolyML.rootFunction
then the resulting program gives this bus error when trying to process anything (such as ?val x = 1;?).
Can you provide some more information and try to narrow the problem down? There certainly shouldn't be bus errors or segmentation faults anywhere.
David