digit-0.7: A data-type representing digits 0-9 and other combinations

Safe HaskellNone
LanguageHaskell2010

Data.Digit.Class.UpperCase

Contents

Synopsis

Classes

class DA d where Source #

Minimal complete definition

dA

Methods

dA :: Prism' d () Source #

xA :: d Source #

Instances
DA () Source # 
Instance details

Defined in Data.Digit.Class.UpperCase

Methods

dA :: Prism' () () Source #

xA :: () Source #

DA HeXDigit Source # 
Instance details

Defined in Data.Digit.Hexadecimal.MixedCase

DA HEXDigit Source # 
Instance details

Defined in Data.Digit.Hexadecimal.UpperCase

class DB d where Source #

Minimal complete definition

dB

Methods

dB :: Prism' d () Source #

xB :: d Source #

Instances
DB () Source # 
Instance details

Defined in Data.Digit.Class.UpperCase

Methods

dB :: Prism' () () Source #

xB :: () Source #

DB HeXDigit Source # 
Instance details

Defined in Data.Digit.Hexadecimal.MixedCase

DB HEXDigit Source # 
Instance details

Defined in Data.Digit.Hexadecimal.UpperCase

class DC d where Source #

Minimal complete definition

dC

Methods

dC :: Prism' d () Source #

xC :: d Source #

Instances
DC () Source # 
Instance details

Defined in Data.Digit.Class.UpperCase

Methods

dC :: Prism' () () Source #

xC :: () Source #

DC HeXDigit Source # 
Instance details

Defined in Data.Digit.Hexadecimal.MixedCase

DC HEXDigit Source # 
Instance details

Defined in Data.Digit.Hexadecimal.UpperCase

class DD d where Source #

Minimal complete definition

dD

Methods

dD :: Prism' d () Source #

xD :: d Source #

Instances
DD () Source # 
Instance details

Defined in Data.Digit.Class.UpperCase

Methods

dD :: Prism' () () Source #

xD :: () Source #

DD HeXDigit Source # 
Instance details

Defined in Data.Digit.Hexadecimal.MixedCase

DD HEXDigit Source # 
Instance details

Defined in Data.Digit.Hexadecimal.UpperCase

class DE d where Source #

Minimal complete definition

dE

Methods

dE :: Prism' d () Source #

xE :: d Source #

Instances
DE () Source # 
Instance details

Defined in Data.Digit.Class.UpperCase

Methods

dE :: Prism' () () Source #

xE :: () Source #

DE HeXDigit Source # 
Instance details

Defined in Data.Digit.Hexadecimal.MixedCase

DE HEXDigit Source # 
Instance details

Defined in Data.Digit.Hexadecimal.UpperCase

class DF d where Source #

Minimal complete definition

dF

Methods

dF :: Prism' d () Source #

xF :: d Source #

Instances
DF () Source # 
Instance details

Defined in Data.Digit.Class.UpperCase

Methods

dF :: Prism' () () Source #

xF :: () Source #

DF HeXDigit Source # 
Instance details

Defined in Data.Digit.Hexadecimal.MixedCase

DF HEXDigit Source # 
Instance details

Defined in Data.Digit.Hexadecimal.UpperCase

Parsers

parseA :: (DA d, CharParsing p) => p d Source #

>>> parse (parseA <* eof) "test" "A" :: Either ParseError HEXDigit
Right HEXDigitA
>>> parse parseA "test" "Axyz" :: Either ParseError HEXDigit
Right HEXDigitA
>>> isn't _Right (parse parseA "test" "xyz" :: Either ParseError HEXDigit)
True

parseB :: (DB d, CharParsing p) => p d Source #

>>> parse (parseB <* eof) "test" "B" :: Either ParseError HEXDigit
Right HEXDigitB
>>> parse parseB "test" "Bxyz" :: Either ParseError HEXDigit
Right HEXDigitB
>>> isn't _Right (parse parseB "test" "xyz" :: Either ParseError HEXDigit)
True

parseC :: (DC d, CharParsing p) => p d Source #

>>> parse (parseC <* eof) "test" "C" :: Either ParseError HEXDigit
Right HEXDigitC
>>> parse parseC "test" "Cxyz" :: Either ParseError HEXDigit
Right HEXDigitC
>>> isn't _Right (parse parseC "test" "xyz" :: Either ParseError HEXDigit)
True

parseD :: (DD d, CharParsing p) => p d Source #

>>> parse (parseD <* eof) "test" "D" :: Either ParseError HEXDigit
Right HEXDigitD
>>> parse parseD "test" "Dxyz" :: Either ParseError HEXDigit
Right HEXDigitD
>>> isn't _Right (parse parseD "test" "xyz" :: Either ParseError HEXDigit)
True

parseE :: (DE d, CharParsing p) => p d Source #

>>> parse (parseE <* eof) "test" "E" :: Either ParseError HEXDigit
Right HEXDigitE
>>> parse parseE "test" "Exyz" :: Either ParseError HEXDigit
Right HEXDigitE
>>> isn't _Right (parse parseE "test" "xyz" :: Either ParseError HEXDigit)
True

parseF :: (DF d, CharParsing p) => p d Source #

>>> parse (parseF <* eof) "test" "F" :: Either ParseError HEXDigit
Right HEXDigitF
>>> parse parseF "test" "Fxyz" :: Either ParseError HEXDigit
Right HEXDigitF
>>> isn't _Right (parse parseF "test" "xyz" :: Either ParseError HEXDigit)
True