rp&      !"#$% 2017 Mark Karpov BSD 3 clause$Mark Karpov <markkarpov92@gmail.com> experimentalportableSafe An &3 wrapper-type for constructing permutation parsers.="Unlifts" a permutation parser into a parser to be evaluated."Unlifts" a permutation parser into a parser to be evaluated with an intercalated effect. Useful for separators between permutation elements.eFor example, suppose that similar to above we want to parse a permutation of: an optional string of a's, the character b and an optional c. Howevery, we also want each element of the permutation to be separated by a colon. Using a standard parsing library combinator char#, this can be described using the & instance by: test = intercalateEffect (char ':') $ (,,) <$?> ("", some (char 'a')) <||> char 'b' <|?> ('_', char 'c')EThis will accept strings such as: "a:b:c", "b:c:a", "b:aa", "b", etc.%Note that the effect is intercalated between! permutation components and that:QThere is never an effect parsed preceeding the first component of the permutationOThere is never an effect parsed following the last component of the permutationLNo effects are intercalated between missing components with a default value.)"Lifts" a parser to a permutation parser.>"Lifts" a parser with a default value to a permutation parser.If no permutation containing the supplied parser can be parsed from the input, then the supplied default value is returned in lieu of a parse result. The expression f <$$> p: creates a fresh permutation parser consisting of parser pB. The the final result of the permutation parser is the function f applied to the return value of p . The parser pD is not allowed to accept empty input use the optional combinator (  ) instead.If the function f2 takes more than one parameter, the type variable bS is instantiated to a functional type which combines nicely with the adds parser p to the ( i) combinator. This results in stylized code where a permutation parser starts with a combining function f( followed by the parsers. The function fl gets its parameters in the order in which the parsers are specified, but actual input can be in any order. The expression  f <$?> (x, p): creates a fresh permutation parser consisting of parser p>. The final result of the permutation parser is the function f applied to the return value of p . The parser p9 is optional if it cannot be applied, the default value x will be used instead. The expression  perm <||> p adds parser p to the permutation parser perm . The parser pD is not allowed to accept empty input use the optional combinator ( ;) instead. Returns a new permutation parser that includes p. The expression perm <||> (x, p) adds parser p to the permutation parser perm . The parser p9 is optional if it cannot be applied, the default value x[ will be used instead. Returns a new permutation parser that includes the optional parser p. 'Permutation specification8Resulting base monad capable of handling the permutation8Effect to be intercalated between permutation componentsPermutation specification8Resulting base monad capable of handling the permutationPermutation component Default ValuePermutation component $Function to use on result of parsing Normal parser Permutation parser build from it $Function to use on result of parsingDefault value and parserPermutation parser Given permutation parser-Parser to add (should not accept empty input)Resulting parser Given permutation parserDefault value and parserResulting parser    '  2 2 1 1 2017 Mark Karpov BSD 3 clause$Mark Karpov <markkarpov92@gmail.com> experimentalportableSafe open close p parses open, followed by p and close!. Returns the value returned by p. *braces = between (symbol "{") (symbol "}") ps( tries to apply the parsers in the list psS in order, until one of them succeeds. Returns the value of the succeeding parser. n p parses n occurrences of p. If n4 is smaller or equal to zero, the parser equals to ( []. Returns a list of n values. See also: . m n p parses from m to n occurrences of p. If n is not positive or m > n, the parser equals to ( []#. Returns a list of parsed values.Please note that m mayK be negative, in this case effect is the same as if it were equal to zero. See also: .Combine two alternatives. p sep parses zero or more occurrences of p, separated and ended by sep'. Returns a list of values returned by p. *cStatements = cStatement `endBy` semicolon p sep parses one or more occurrences of p, separated and ended by sep'. Returns a list of values returned by p. p end applies parser p zero or more times until parser end2 succeeds. Returns the list of values returned by p. See also: , . p end works similarly to  p end, but p should succeed at least once. See also: ,  . x p tries to apply the parser p. If p6 fails without consuming input, it returns the value x#, otherwise the value returned by p. .priority = option 0 (digitToInt <$> digitChar) See also: . p sep parses zero or more occurrences of p, separated by sep'. Returns a list of values returned by p. commaSep p = p `sepBy` comma p sep parses one or more occurrences of p, separated by sep'. Returns a list of values returned by p. p sep parses zero or more occurrences of p%, separated and optionally ended by sep'. Returns a list of values returned by p. p sep parses one or more occurrences of p%, separated and optionally ended by sep'. Returns a list of values returned by p. p applies the parser p zero% or more times, skipping its result. See also: , . p applies the parser p one% or more times, skipping its result. See also: ,  . p end applies the parser p zero. or more times skipping results until parser end succeeds. Result parsed by end is then returned. See also: , .   p end applies the parser p one. or more times skipping results until parser end succeeds. Result parsed by end is then returned. See also: , .     2017 Mark Karpov BSD 3 clause$Mark Karpov <markkarpov92@gmail.com> experimentalportableSafe!! p applies the parser p one= or more times and returns a list of the returned values of p. word = some letter"" p sep parses one or more occurrences of p, separated and ended by sep1. Returns a non-empty list of values returned by p.## p end works similarly to  p end, but p should succeed at least once. See also: ,  .$$ p sep parses one or more occurrences of p, separated by sep1. Returns a non-empty list of values returned by p.%% p sep parses one or more occurrences of p%, separated and optionally ended by sep2. Returns a non-empty list of values returned by p.!"#$%!"#$%!"#$%!"#$%)      !"#$%&' !#()*+/parser-combinators-0.2.1-97Fpn0gq6jJ3kcperg4ttuControl.Applicative.Combinators Control.Applicative.Permutations(Control.Applicative.Combinators.NonEmptybaseControl.ApplicativeoptionalGHC.Basemanysome<|> PermutationrunPermutationintercalateEffect toPermutationtoPermutationWithDefault<$$><$?><||><|?>$fApplicativePermutation$fFunctorPermutationbetweenchoicecountcount'eitherPendByendBy1manyTillsomeTilloptionsepBysepBy1sepEndBy sepEndBy1skipManyskipSome skipManyTill skipSomeTill ApplicativePpure