[GHC] #8542: Suggest NegativeLiterals

GHC ghc-devs at haskell.org
Tue Nov 19 15:11:27 UTC 2013


#8542: Suggest NegativeLiterals
-------------------------------------+------------------------------------
        Reporter:  monoidal          |            Owner:
            Type:  bug               |           Status:  patch
        Priority:  normal            |        Milestone:
       Component:  Compiler          |          Version:  7.7
      Resolution:                    |         Keywords:
Operating System:  Unknown/Multiple  |     Architecture:  Unknown/Multiple
 Type of failure:  None/Unknown      |       Difficulty:  Unknown
       Test Case:                    |       Blocked By:
        Blocking:                    |  Related Tickets:
-------------------------------------+------------------------------------
Changes (by monoidal):

 * status:  new => patch


Comment:

 Patch attached. It also gives an (incorrect) suggestion for 128 :: Int8,
 but this shouldn't matter.

 While we are at it: to determine whether an `Int` literal is correct we
 test with `minBound :: Int` and `maxBound :: Int`. This can vary between
 machines. Should this be changed to testing against `2^30` or something
 similar?

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/8542#comment:1>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list