[GHC] #13235: (makeVersion [4, 9, 0, 0] <= makeVersion [4, 9]) == False

GHC ghc-devs at haskell.org
Mon Feb 6 13:16:46 UTC 2017


#13235: (makeVersion [4, 9, 0, 0] <= makeVersion [4, 9]) == False
-------------------------------------+-------------------------------------
           Reporter:  varosi         |             Owner:
               Type:  bug            |            Status:  new
           Priority:  normal         |         Milestone:
          Component:                 |           Version:  8.0.1
  libraries/base                     |
           Keywords:                 |  Operating System:  Unknown/Multiple
       Architecture:                 |   Type of failure:  None/Unknown
  Unknown/Multiple                   |
          Test Case:                 |        Blocked By:
           Blocking:                 |   Related Tickets:
Differential Rev(s):                 |         Wiki Page:
-------------------------------------+-------------------------------------
 I have hit a strange bug in cabal project. Zeroes in Version have meaning,
 which is not logical (at least mathematically). See this example:


 {{{
 import Data.Version
 makeVersion [4, 9, 0, 0] <= makeVersion [4, 9]
 False
 }}}


 I propose to add zeroes to the version with less numbers, so they could be
 equally compared.

 Related discussion: https://github.com/commercialhaskell/stack/issues/2948

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


More information about the ghc-tickets mailing list