Copyright | (C) 2021 Koz Ross |
---|---|
License | Apache 2.0 |
Maintainer | Koz Ross <koz.ross@retro-freedom.nz> |
Stability | unstable, not subject to PVP |
Portability | GHC only |
Safe Haskell | Trustworthy |
Language | Haskell2010 |
This is an internal module, and is not subject to the PVP. It can change in any way, at any time, and should not be depended on unless you know exactly what you are doing. You have been warned.
Documentation
>>>
:set -XQuasiQuotes
>>>
import Text.Ascii.QQ
char :: QuasiQuoter Source #
Allows constructing ASCII characters from literals, whose correctness is checked by the compiler.
Currently, accepts literal syntax similar to the Haskell parser, with escape sequences preceded by '\'. In particular, this includes the single quote (see the example below).
>>>
[char| '\'' |]
'0x27'
Since: 1.0.0
ascii :: QuasiQuoter Source #
Allows constructing ASCII strings from literals, whose correctness is checked by the compiler.
Currently accepts literal syntax similar to the Haskell parser, with escape sequences preceded by '\'. In particular, this includes the double quote (see the example below).
>>>
[ascii| "\"Nyan!\", said the catboy." |]
"\"Nyan!\", said the catboy."
Since: 1.0.0
isValidLead :: Char -> Bool Source #