
#15627: Absent unlifted bindings -------------------------------------+------------------------------------- Reporter: sgraf | Owner: (none) Type: task | Status: new Priority: normal | Milestone: ⊥ Component: Compiler | Version: 8.4.3 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: #9279 #4328 | Differential Rev(s): #11126 | Wiki Page: | -------------------------------------+------------------------------------- Comment (by simonpj): Ah I see. The problem is that we are using `Literal` in `IfaceSyn`, and that is biting us here; it would be more consistent to have `IfaceLiteral`. If we did we could have {{{ data IfaceLiteral = ... | RubbishLit IfaceType | LitNumber LitNumType Integer -- No Type here; we reconstruct it in tcIfaceLit -- Avoids the smelly error-thunk in the Binary get ... }}} It's annoying that `Literal` and `IfaceLiteral` would be almost the same; some boilerplate converting to and fro. But it's ''simple'' boilerplate, and uniform with everything else. And it avoids that nasty error thunk in the binary instance of Literal. I suppose that a polymorphic literal as you suggest would be OK. You could avoid the levity polymorphism by retaining `MachNullAddr`. I'm not sure which I prefer. The `IfaceLiteral` story is less clever, and thus perhaps preferable. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/15627#comment:3 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler