text-ascii-1.1: ASCII string and character processing.
Copyright(C) 2021 Koz Ross
LicenseApache 2.0
MaintainerKoz Ross <koz.ross@retro-freedom.nz>
Stabilityunstable, not subject to PVP
PortabilityGHC only
Safe HaskellTrustworthy
LanguageHaskell2010

Text.Ascii.QQ

Description

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.

Synopsis

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