[GHC] #16300: Make TH always reify data types with explicit return kinds
GHC
ghc-devs at haskell.org
Mon Feb 11 21:33:56 UTC 2019
#16300: Make TH always reify data types with explicit return kinds
-------------------------------------+-------------------------------------
Reporter: RyanGlScott | Owner: (none)
Type: feature request | Status: new
Priority: normal | Milestone:
Component: Template Haskell | Version: 8.6.3
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture:
| Unknown/Multiple
Type of failure: None/Unknown | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by RyanGlScott):
Replying to [comment:6 goldfire]:
> Actually, maybe it would be better to have `qTypeKind :: Type -> Q Kind`
and `qExprType :: Exp -> Q Type`. Then, we can avoid this whole kerfuffle
for unlifted newtypes by requiring clients to just get the kind of the
argument.
That's an intriguing idea.
> Note that these two functions would not be particularly hard to write
but would be very useful.
While I imagine one could implement these functions, I wonder what their
specification should be. What should they do if their inputs are ill
typed, for instance? Also, the answers that they return might change
depending on whether certain language extensions are enabled.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/16300#comment:7>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list