mosml
mosml copied to clipboard
real should not admit equality
Currently, real is an eqtype which it shouldn't be, according to the SML Standard (see Appendix C). In particular, the following code should fail to elaborate:
1.0 = 1.0;
fn x => x = 1.0;
Further, the current equality on real does not work too well (as one would expect, I'd say):
Moscow ML version 2.10
Enter `quit();' to quit.
- 1.0000000000000001 = 1.0;
> val it = true : bool
- 1.0000000000000001;
> val it = 1.0 : real