[GHC] #13023: strange behaviour of GHCi when int value exceed int range
GHC
ghc-devs at haskell.org
Wed Dec 21 16:42:55 UTC 2016
#13023: strange behaviour of GHCi when int value exceed int range
-------------------------------------+-------------------------------------
Reporter: vanto | Owner:
Type: bug | Status: closed
Priority: normal | Milestone:
Component: GHCi | Version: 8.0.1
Resolution: invalid | Keywords:
Operating System: Unknown/Multiple | Architecture:
| Unknown/Multiple
Type of failure: GHCi crash | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Changes (by rwbarton):
* status: new => closed
* resolution: => invalid
Comment:
I assume this is on a 32-bit system.
Consider the fact that {{{(-1) `div` 2 = -1}}} and that repeatedly
applying {{{`div` 2}}} to a negative `Int` (like `4200000000 = -94967296`)
will eventually reach `-1`.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/13023#comment:1>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list