{-# LANGUAGE CPP               #-}
{-# LANGUAGE OverloadedStrings #-}

#include "version-compatibility-macros.h"

-- | Common symbols composed out of the ASCII subset of Unicode. For non-ASCII
-- symbols, see "Prettyprinter.Symbols.Unicode".
module Prettyprinter.Symbols.Ascii where



import Prettyprinter.Internal



-- | >>> squotes "·"
-- '·'
squotes :: Doc ann -> Doc ann
squotes :: Doc ann -> Doc ann
squotes = Doc ann -> Doc ann -> Doc ann -> Doc ann
forall ann. Doc ann -> Doc ann -> Doc ann -> Doc ann
enclose Doc ann
forall ann. Doc ann
squote Doc ann
forall ann. Doc ann
squote

-- | >>> dquotes "·"
-- "·"
dquotes :: Doc ann -> Doc ann
dquotes :: Doc ann -> Doc ann
dquotes = Doc ann -> Doc ann -> Doc ann -> Doc ann
forall ann. Doc ann -> Doc ann -> Doc ann -> Doc ann
enclose Doc ann
forall ann. Doc ann
dquote Doc ann
forall ann. Doc ann
dquote

-- | >>> parens "·"
-- (·)
parens :: Doc ann -> Doc ann
parens :: Doc ann -> Doc ann
parens = Doc ann -> Doc ann -> Doc ann -> Doc ann
forall ann. Doc ann -> Doc ann -> Doc ann -> Doc ann
enclose Doc ann
forall ann. Doc ann
lparen Doc ann
forall ann. Doc ann
rparen

-- | >>> angles "·"
-- <·>
angles :: Doc ann -> Doc ann
angles :: Doc ann -> Doc ann
angles = Doc ann -> Doc ann -> Doc ann -> Doc ann
forall ann. Doc ann -> Doc ann -> Doc ann -> Doc ann
enclose Doc ann
forall ann. Doc ann
langle Doc ann
forall ann. Doc ann
rangle

-- | >>> brackets "·"
-- [·]
brackets :: Doc ann -> Doc ann
brackets :: Doc ann -> Doc ann
brackets = Doc ann -> Doc ann -> Doc ann -> Doc ann
forall ann. Doc ann -> Doc ann -> Doc ann -> Doc ann
enclose Doc ann
forall ann. Doc ann
lbracket Doc ann
forall ann. Doc ann
rbracket

-- | >>> braces "·"
-- {·}
braces :: Doc ann -> Doc ann
braces :: Doc ann -> Doc ann
braces = Doc ann -> Doc ann -> Doc ann -> Doc ann
forall ann. Doc ann -> Doc ann -> Doc ann -> Doc ann
enclose Doc ann
forall ann. Doc ann
lbrace Doc ann
forall ann. Doc ann
rbrace

-- | >>> squote
-- '
squote :: Doc ann
squote :: Doc ann
squote = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
'\''

-- | >>> dquote
-- "
dquote :: Doc ann
dquote :: Doc ann
dquote = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
'"'

-- | >>> lparen
-- (
lparen :: Doc ann
lparen :: Doc ann
lparen = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
'('

-- | >>> rparen
-- )
rparen :: Doc ann
rparen :: Doc ann
rparen = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
')'

-- | >>> langle
-- <
langle :: Doc ann
langle :: Doc ann
langle = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
'<'

-- | >>> rangle
-- >
rangle :: Doc ann
rangle :: Doc ann
rangle = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
'>'

-- | >>> lbracket
-- [
lbracket :: Doc ann
lbracket :: Doc ann
lbracket = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
'['
-- | >>> rbracket
-- ]
rbracket :: Doc ann
rbracket :: Doc ann
rbracket = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
']'

-- | >>> lbrace
-- {
lbrace :: Doc ann
lbrace :: Doc ann
lbrace = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
'{'
-- | >>> rbrace
-- }
rbrace :: Doc ann
rbrace :: Doc ann
rbrace = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
'}'

-- | >>> semi
-- ;
semi :: Doc ann
semi :: Doc ann
semi = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
';'

-- | >>> colon
-- :
colon :: Doc ann
colon :: Doc ann
colon = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
':'

-- | >>> comma
-- ,
comma :: Doc ann
comma :: Doc ann
comma = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
','

-- | >>> "a" <> space <> "b"
-- a b
--
-- This is mostly used via @'<+>'@,
--
-- >>> "a" <+> "b"
-- a b
space :: Doc ann
space :: Doc ann
space = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
' '

-- | >>> dot
-- .
dot :: Doc ann
dot :: Doc ann
dot = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
'.'

-- | >>> slash
-- /
slash :: Doc ann
slash :: Doc ann
slash = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
'/'

-- | >>> backslash
-- \\

backslash :: Doc ann
backslash :: Doc ann
backslash = Doc ann
"\\"

-- | >>> equals
-- =
equals :: Doc ann
equals :: Doc ann
equals = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
'='

-- | >>> pipe
-- |
pipe :: Doc ann
pipe :: Doc ann
pipe = Char -> Doc ann
forall ann. Char -> Doc ann
Char Char
'|'



-- $setup
--
-- (Definitions for the doctests)
--
-- >>> :set -XOverloadedStrings
-- >>> import Data.Semigroup
-- >>> import Prettyprinter.Render.Text
-- >>> import Prettyprinter.Util