[GHC] #12049: `OverloadedStrings` for types

#12049: `OverloadedStrings` for types -------------------------------------+------------------------------------- Reporter: Iceland_jack | Owner: Type: feature | Status: new request | Priority: normal | Milestone: Component: Compiler | Version: 7.10.3 Keywords: | Operating System: Unknown/Multiple CustomTypeErrors | Architecture: | Type of failure: None/Unknown Unknown/Multiple | Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- Is there any sense in adding {{{#!hs class IsSymbol a where type FromSymbol (str :: Symbol) :: a instance IsSymbol ErrorMessage where type FromSymbol str = GHC.TypeLits.Text str instance IsSymbol ErrorMessage where type FromSymbol str = str }}} where `FromSymbol` gets placed before type-level string literals: {{{#!hs TypeError ("Warning: ":<>:ShowType ty:<>:" is odd.") }}} analogous to `Data.String.IsString`. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12049 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler
participants (1)
-
GHC