[GHC] #9984: Show, Read, Eq, Ord instances for Control.Applicative.Const

#9984: Show, Read, Eq, Ord instances for Control.Applicative.Const -------------------------------------+------------------------------------- Reporter: fumieval | Owner: Type: feature | Status: new request | Milestone: Priority: low | Version: 7.8.4 Component: | Operating System: Unknown/Multiple libraries/base | Type of failure: None/Unknown Keywords: | Blocked By: Architecture: | Related Tickets: Unknown/Multiple | Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- As mentioned in https://www.haskell.org/pipermail/libraries/2013-October/021531.html, the following instances can be derived clearly: * `Show a => Show (Const a b)` * `Read a => Read (Const a b)` * `Eq a => Eq (Const a b)` * `Ord a => Ord (Const a b)` The absence of these instances makes debugging harder. I suggest handcrafted Show/Read instances for neat representation. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9984 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#9984: Show, Read, Eq, Ord instances for Control.Applicative.Const -------------------------------------+------------------------------------- Reporter: fumieval | Owner: Type: feature request | Status: new Priority: low | Milestone: Component: libraries/base | Version: 7.8.4 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: None/Unknown | Unknown/Multiple Blocked By: | Test Case: Related Tickets: | Blocking: | Differential Revisions: -------------------------------------+------------------------------------- Comment (by ekmett): We determined in response to a similar earlier ticket that such instances should just be added where they are obvious and can be added unambiguously, so I don't see any issue at all with adding these. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9984#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#9984: Show, Read, Eq, Ord instances for Control.Applicative.Const -------------------------------------+------------------------------------- Reporter: fumieval | Owner: Type: feature request | Status: new Priority: low | Milestone: Component: libraries/base | Version: 7.8.4 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: None/Unknown | Unknown/Multiple Blocked By: | Test Case: Related Tickets: | Blocking: | Differential Revisions: -------------------------------------+------------------------------------- Comment (by hvr): fumieval, I'd either need a patch w/ your proper email-address (including a real-name) otherwise we can't properly attribute the patch to you... You can use either `git format-patch -1` for that or, if you want, you can also submit the patch to our wiki:Phabricator instance. Edward, is this GHC 7.10.1 material? -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9984#comment:2 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#9984: Show, Read, Eq, Ord instances for Control.Applicative.Const -------------------------------------+------------------------------------- Reporter: fumieval | Owner: Type: feature request | Status: new Priority: low | Milestone: Component: libraries/base | Version: 7.8.4 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: None/Unknown | Unknown/Multiple Blocked By: | Test Case: Related Tickets: | Blocking: | Differential Revisions: -------------------------------------+------------------------------------- Comment (by fumieval): I apologize for my clumsiness. I've just uploaded an appropriate one. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9984#comment:3 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#9984: Show, Read, Eq, Ord instances for Control.Applicative.Const -------------------------------------+------------------------------------- Reporter: fumieval | Owner: Type: feature request | Status: patch Priority: low | Milestone: 7.10.1 Component: libraries/base | Version: 7.8.4 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: None/Unknown | Unknown/Multiple Blocked By: | Test Case: Related Tickets: | Blocking: | Differential Revisions: Phab:D619 -------------------------------------+------------------------------------- Changes (by hvr): * status: new => patch * differential: => Phab:D619 * milestone: => 7.10.1 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9984#comment:4 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#9984: Show, Read, Eq, Ord instances for Control.Applicative.Const -------------------------------------+------------------------------------- Reporter: fumieval | Owner: Type: feature request | Status: patch Priority: low | Milestone: 7.10.1 Component: libraries/base | Version: 7.8.4 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: None/Unknown | Unknown/Multiple Blocked By: | Test Case: Related Tickets: | Blocking: | Differential Revisions: Phab:D619 -------------------------------------+------------------------------------- Comment (by ekmett): I'd have no objection to including it in 7.10.1. The fact that these instances are missing is actually rather surprising to me. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9984#comment:5 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#9984: Show, Read, Eq, Ord instances for Control.Applicative.Const
-------------------------------------+-------------------------------------
Reporter: fumieval | Owner:
Type: feature request | Status: patch
Priority: low | Milestone: 7.10.1
Component: libraries/base | Version: 7.8.4
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture:
Type of failure: None/Unknown | Unknown/Multiple
Blocked By: | Test Case:
Related Tickets: | Blocking:
| Differential Revisions: Phab:D619
-------------------------------------+-------------------------------------
Comment (by Herbert Valerio Riedel

#9984: Show, Read, Eq, Ord instances for Control.Applicative.Const -------------------------------------+------------------------------------- Reporter: fumieval | Owner: Type: feature request | Status: closed Priority: low | Milestone: 7.10.1 Component: libraries/base | Version: 7.8.4 Resolution: fixed | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: None/Unknown | Unknown/Multiple Blocked By: | Test Case: Related Tickets: | Blocking: | Differential Revisions: Phab:D619 -------------------------------------+------------------------------------- Changes (by hvr): * status: patch => closed * resolution: => fixed Comment: also applied to 7.10 with [aaca7bdf/ghc] -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9984#comment:7 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler
participants (1)
-
GHC