[GHC] #11529: Show instance of Char should print literals for non-ascii printable charcters
GHC
ghc-devs at haskell.org
Wed Feb 3 04:42:14 UTC 2016
#11529: Show instance of Char should print literals for non-ascii printable
charcters
-------------------------------------+-------------------------------------
Reporter: nushio | Owner:
Type: bug | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 7.10.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 nushio):
Dear dfeuer, thank you for pointing out that the `Show Char` is specified
in Haskell 2010. I believe the corresponding section is the following:
https://www.haskell.org/onlinereport/haskell2010/haskellch16.html#x24-21700016.6
{{{
16.6 String representations
showLitChar :: Char -> ShowS
Convert a character to a string using only printable characters,
using Haskell source-language escape conventions. For example:
showLitChar '\n' s = "\\n" ++ s
}}}
where "Haskell source-language escape conventions" are defined, in turn,
in Section 2.6
https://www.haskell.org/onlinereport/haskell2010/haskellch2.html#x7-200002.6
.
Correct me if I'm wrong.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11529#comment:3>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list