h*.p&      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~                                                                                      1.0.1 Safe-Inferred )1=> Safe-Inferred )1=> symparsec.Promoted parsers with singled implementations. symparsec!A singleton for the parser state.  symparsec'A singleton for the parser return type.  symparsecThe singled parser. symparsec Promoted . symparsec Parser error.Promotable. Instantiate with  for term-level,  for type-level. symparsecBase parser error. symparsec%Inner parser error inside combinator. symparsec Promoted . symparsec(The result of a single step of a parser.Promotable. Instantiate with  for term-level,  for type-level. Note that a  indicates the parser has not consumed the character. In the original design, it did consume it, and parsers did their own "lookahead" to handle this. The non-consuming behaviour simplifies permitting non-consuming parsers such as Take 0. symparsec&OK, consumed, continue with state s symparsec.OK, not consumed, parse succeeded with result r  symparsec parse error% symparsec#A defunctionalization symbol for a '.' symparsec(What a parser should do at the end of a .* symparsec5A partially-applied defunctionalization symbol for a -.+ symparsec#A defunctionalization symbol for a -.- symparsecParse a  with the given state.. symparsecA singled parser.TODO consider swapping for STuple3...? this is much easier though0 symparsecA symparsecHelper for writing error messages to do with parser limitations (e.g. if you tried to use a non-consuming parser like Skip 0).B symparsec>Fail with the given message if we're at the end of the symbol. symparsec>Fail with the given message when given any character to parse.5678901234./-,+*)('&%$#"!     :;<CDBEA CDBEA Safe-Inferred )1=>H symparsecAssert end of symbol, or fail.FGHIJHIGFJ Safe-Inferred )1=>aY symparsec*Run the given parser isolated to the next n characters.)All isolated characters must be consumed.LMNOPQRSTUVWXYZ[\]^_`aYXWZV[UT\S]R^QPON_M`La Safe-Inferred )1=>k symparsecParse the given .cdefghijklmnopkljihmgfnedocp Safe-Inferred )1=>*s symparsec&Parse a hexadecimal digit (0-9A-Fa-f).(Both upper and lower case are permitted.u symparsecParse a decimal digit (0-9).w symparsecParse an octal digit (0-7).y symparsecParse a binary digit (0 or 1).rstuvwxyz{|}~|z{yx}wv~utsr Safe-Inferred )1=> symparsecParse a natural in the given base, using the given digit parser. symparsec;Parse a hexadecimal (base 16) natural. Permits mixed-case ( 0-9A-Fa-f). symparsec"Parse a decimal (base 10) natural. symparsec Parse an octal (base 8) natural. symparsec Parse a binary (base 2) natural. Safe-Inferred )1=>s symparsecLimited parser choice. Try left; if it fails, backtrack and try right. However, _the right choice must consume at least as much as the left choice._ If it doesn't, then even if the right parser succeeds, it will emit an error.This behaviour is due to the parser runner not supporting backtracking. We can emulate it by storing a record of the characters parsed so far, and "replaying" these on the right parser if the left parser fails. If the right parser ends before we finish replaying, we will have consumed extra characters that we can't ask the runner to revert. For example, Literal "abcd" : |: Literal "ab" is bad. An input of abcX$ will trigger the consumption error.I can't think of another way to implement this with the current parser design. I think it's the best we have. A more complex parser design may permit changing internal running state, so we could save and load state (this would permit a Try p parser). But that's scary. And you're better off designing your type-level string schemas to permit non-backtracking parsing anyway...Also problematic is that we never emit a left parser error, so errors can degrade. Perhaps your string was one character off a successful left parse; but if it fails, you won't see that error.3  Safe-Inferred )1=> symparsec Skip forward n! characters. Fails if fewer than n characters are available'.    Safe-Inferred )1=>2 symparsecReturn the next n characters.    Safe-Inferred )1=> symparsec"Return the remaining input string.  Safe-Inferred )1=> symparsecSequence two parsers, running left then right, and return both results.4  Safe-Inferred )1=> symparsecSequence two parsers, running left then right, and discard the return value of the left parser.4 Safe-Inferred )1=> symparsecSequence two parsers, running left then right, and discard the return value of the right parser.4 Safe-Inferred )1=> THYkHYk Safe-Inferred)1=>&  symparsec Promoted . symparsecError while running parser. symparsec%Parser error at index X, character C. symparsec!Parser error on the empty string. symparsecInspect end parser result for the empty string, where we have no previous character or (meaningful) index. symparsecInspect end parser result. symparsec Inspect character parser result.This is purposely written so that the main case is at the top, and a single equation (we parse, prepare next character and inspect character parser result at the same time). My hope is that this keeps GHC fast. symparsec"Run the given parser on the given &, emitting a type error on failure.This would be useful for :k!* runs, but it doesn't work properly with  s, printing = (TypeError ...) instead of the error message. Alas! Instead, do something like > Proxy @(RunTest ...). symparsec"Run the given parser on the given , returning a  on failure. symparsec"Run the given parser on the given , returning an  on failure. symparsec:Run the singled version of type-level parser on the given , returning an  on failure.You must provide a function for demoting the singled return type. ($ can do this for you automatically.) Safe-Inferred )1=>&HYk !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFFGGHIJKKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~                                                                                      symparsec-1.0.1-inplaceSymparsec.Parser.CommonSymparsec.ParserSymparsec.Parser.EndSymparsec.Parser.IsolateSymparsec.Parser.LiteralSymparsec.Parser.Natural.DigitsSymparsec.Parser.NaturalSymparsec.Parser.OrSymparsec.Parser.SkipSymparsec.Parser.TakeSymparsec.Parser.TakeRestSymparsec.Parser.ThenSymparsec.Parser.Then.VoidLeftSymparsec.Parser.Then.VoidRight Symparsec.Run symparsecPaths_symparsecSymparsec.Parsers Symparsec%defun-core-0.1-3rWaObiIe7EH66VviRU5x6 DeFun.Core@@App~>,type-level-show-0.2.1-BPiUrqpWItDL0UehUBV3r7TypeLevelShow.DocDocText:<>::$$: SingParserPSPR singParser'SingEsingESESEBaseSEInPEEEBaseEIn SResultSInit PResultSInit SResultEnd PResultEndSResultSContSDoneSErrPResultResultContDoneErrSParserSInitSymParserSInitSym ParserSInit SParserEndSym ParserEndSym PParserEnd ParserEnd SParserChSym1 SParserChSym ParserChSym1 ParserChSym PParserChParserChSParserPParser pparserCh pparserEnd pparserS0ParserparserCh parserEndparserS0demoteSE withSingE singParser$fDemotableESE $fSingEEIn $fSingEEBase$fShowEErrParserLimitation FailEndSym FailChSym failChSym failEndSym EndChSym1EndChSymEndsEnd sEndChSym$fSingParser()()PParserEIsolateRemaining EIsolateEndN EIsolateWrap IsolateChSym1 IsolateChSym IsolateEndSym IsolateEnd' IsolateEnd IsolateInnerIsolateInnerEnd IsolateCh SIsolateSIsolate'IsolatesIsolate sIsolateChSym sIsolateInnersIsolateEndSym sIsolateEnd' eIsolateWrap eIsolateEndNeIsolateRemaining$fSingParser(,)rPParser LiteralEndSym EStillParsing LiteralEnd LiteralChSym1 LiteralChSym EWrongChar LiteralCh' LiteralChLiteralsLiteral eWrongChar sLiteralChSym eStillParsingsLiteralEndSym$fSingParserSymbol()PParserParseDigitHexSym ParseDigitHexParseDigitDecSym ParseDigitDecParseDigitOctSym ParseDigitOctParseDigitBinSym ParseDigitBinSingParseDigitsingParseDigit SParseDigitsParseDigitBinSymsParseDigitOctSymsParseDigitDecSymsParseDigitHexSym $fSingParseDigitParseDigitBinSym $fSingParseDigitParseDigitOctSym $fSingParseDigitParseDigitDecSym $fSingParseDigitParseDigitHexSym NatBaseEndSymEEmpty NatBaseEnd NatBaseChSym1 NatBaseChSym EInvalidDigit NatBaseCh' NatBaseChNatBaseNatHexNatDecNatOctNatBinsNatBase eInvalidDigit sNatBaseChSymeEmptysNatBaseEndSym$fSingParserMaybeNaturalPParserOrEndSymOrChSym1OrChSym OrEndLReplay' OrEndLReplayOrEndLOrEndROrEndOrChREOrStillReplayingEOrR OrChLReplayOrChLOrChSPOrOrSSOrSOr':<|>:sOr sOrChLReplayeOrReOrStillReplayingsOrChRsOrEndRsOrEndL sOrEndLReplaysOrChSymsOrChL sOrEndSym$fSingParserEitherEitherPParser SkipEndSym ESkipPastEndSkipEnd SkipChSym1 SkipChSymSkipChSkipsSkip sSkipChSym eSkipPastEnd sSkipEndSym$fSingParserNatural()PParser TakeEndSymETakeEndTakeEnd TakeChSym1 TakeChSymTakeChTakeSSTakeSTakesTake sTakeChSymeTakeEnd sTakeEndSym$fSingParser(,)SymbolPParserTakeRestEndSymTakeRestChSym1 TakeRestChSymTakeRest sTakeRestsTakeRestChSymsTakeRestEndSym$fSingParserListSymbolPParser ThenEndSym EThenEndLThenEndL EThenEndRThenEndRThenEnd ThenChSym1 ThenChSymEThenChRThenChREThenChLThenChLThenChThen':<*>:SPThensTheneThenChLeThenChRsThenChR sThenChSym eThenEndR sThenEndR eThenEndL sThenEndSym$fSingParserEither(,)PParser ThenVLEndSym EThenVLEndL ThenVLEndL EThenVLEndR ThenVLEndR ThenVLEnd ThenVLChSym1 ThenVLChSym EThenVLChR ThenVLChR EThenVLChL ThenVLChLThenVLChThenVL':*>:SPThenVLsThenVL eThenVLChL eThenVLChR sThenVLChR sThenVLChSym eThenVLEndR sThenVLEndR eThenVLEndL sThenVLEndSym$fSingParserEitherrPParser ThenVREndSym EThenVREndL ThenVREndL EThenVREndR ThenVREndR ThenVREnd ThenVRChSym1 ThenVRChSym EThenVRChR ThenVRChR EThenVRChL ThenVRChLThenVRChThenVR':<*:SPThenVRsThenVR eThenVRChL eThenVRChR sThenVRChR sThenVRChSym eThenVREndR sThenVREndR eThenVREndL sThenVREndSymSERunSERun0PERunERunERun0PrettyE PrettyERunRunEnd0RunEndRunChMapLeftTypeErrorRunStartRunTestRun' MapLeftRenderRunrun'runTestsRun' sRunStartsRunChsRunEndsRunEnd0 demoteSERun$fDemotableERunSERun $fShowERunversion getBinDir getLibDir getDynLibDir getDataDir getLibexecDirgetDataFileName getSysconfDirbaseGHC.BaseStringghc-prim GHC.TypesSymbolCharFailCh GHC.TypeError TypeError ErrorMessage'singleraeh-0.2.0-D1VD0g8QUmi2dqkrUZwMtUSingleraeh.Demotedemote