typed-racket
typed-racket copied to clipboard
`abs` should add a case for `(-> Fixnum Nonnegative-Fixnum)`
See https://github.com/racket/typed-racket/issues/1309 for a motivating example.
One thing that should be looked out for is that (most-positive-fixnum) is less than (abs (most-negative-fixnum)) by one.
Yes, as @sorawee points out this is unfortunately not true:
> (fixnum? (abs (most-negative-fixnum)))
#f