[GHC] #10104: Show '#' on unboxed literals

#10104: Show '#' on unboxed literals -------------------------------------+------------------------------------- Reporter: thomie | Owner: Type: feature | Status: new request | Milestone: 7.12.1 Priority: normal | Version: 7.8.4 Component: Compiler | Operating System: Unknown/Multiple Keywords: | Type of failure: None/Unknown Architecture: | Blocked By: Unknown/Multiple | Related Tickets: #8274 Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- Currently, unboxed literals are shown in the same way as boxed literals (without #): {{{ Prelude> :set -XMagicHash Prelude> :m GHC.Prim Prelude GHC.Prim> data T = MkT Int# deriving Show Prelude GHC.Prim> MkT 3# MkT 3 }}} It would be nice if this would show `MkT 3#` instead. I have a patch. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/10104 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#10104: Show '#' on unboxed literals -------------------------------------+------------------------------------- Reporter: thomie | Owner: Type: feature request | Status: patch Priority: normal | Milestone: 7.12.1 Component: Compiler | Version: 7.8.4 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: None/Unknown | Unknown/Multiple Blocked By: | Test Case: Related Tickets: #8274 | Blocking: | Differential Revisions: Phab:D672 -------------------------------------+------------------------------------- Changes (by thomie): * status: new => patch * differential: => Phab:D672 Comment: Also handle `Char#`, `Word#`, `Float#` and `Double#`. And don't show superfluous parenthesis around negative unboxed literals. For reference: https://downloads.haskell.org/~ghc/latest/docs/html/users_guide/syntax- extns.html#magic-hash -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/10104#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#10104: Show '#' on unboxed literals -------------------------------------+------------------------------------- Reporter: thomie | Owner: Type: feature request | Status: patch Priority: normal | Milestone: 7.12.1 Component: Compiler | Version: 7.8.4 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: None/Unknown | Unknown/Multiple Blocked By: | Test Case: Related Tickets: #8274 | deriving/should_run/T10104 | Blocking: | Differential Revisions: Phab:D672 -------------------------------------+------------------------------------- Changes (by thomie): * testcase: => deriving/should_run/T10104 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/10104#comment:2 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#10104: Show '#' on unboxed literals
-------------------------------------+-------------------------------------
Reporter: thomie | Owner:
Type: feature request | Status: patch
Priority: normal | Milestone: 7.12.1
Component: Compiler | Version: 7.8.4
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture:
Type of failure: None/Unknown | Unknown/Multiple
Blocked By: | Test Case:
Related Tickets: #8274 | deriving/should_run/T10104
| Blocking:
| Differential Revisions: Phab:D672
-------------------------------------+-------------------------------------
Comment (by Austin Seipp

#10104: Show '#' on unboxed literals -------------------------------------+------------------------------------- Reporter: thomie | Owner: Type: bug | Status: closed Priority: normal | Milestone: 7.12.1 Component: Compiler | 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: #8274 | deriving/should_run/T10104 | Blocking: | Differential Revisions: Phab:D672 -------------------------------------+------------------------------------- Changes (by thoughtpolice): * status: patch => closed * type: feature request => bug * resolution: => fixed Comment: Merged, thanks! -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/10104#comment:4 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#10104: Show '#' on unboxed literals
-------------------------------------+-------------------------------------
Reporter: thomie | Owner:
Type: bug | Status: closed
Priority: normal | Milestone: 7.12.1
Component: Compiler | 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: #8274 | deriving/should_run/T10104
| Blocking:
| Differential Revisions: Phab:D672
-------------------------------------+-------------------------------------
Comment (by Austin Seipp
participants (1)
-
GHC