regex-0.12.0.0: Toolkit for regex-base

Safe HaskellNone
LanguageHaskell2010

Text.RE.ZeInternals.PreludeMacros

Synopsis

Documentation

data RegexType Source #

what flavour of regex are we dealing with

data WithCaptures Source #

do we need the captures in the RE or whould they be stripped out where possible

Constructors

InclCaptures

include all captures

ExclCaptures

remove captures where possible

data MacroDescriptor Source #

describes a macro, giving the text of the RE and a si=ummary description

Constructors

MacroDescriptor 

Fields

newtype RegexSource Source #

a RE that should work for POSIX and PCRE with open brackets ('(') represented as follows: ( mere symbol (?: used for grouping only, not for captures (}: used for captures only, not for grouping (]: used for captures and grouping ( do not modify

Constructors

RegexSource 

Fields

data PreludeMacro Source #

an enumeration of all of the prelude macros

preludeMacros :: (Monad m, Functor m) => (String -> m r) -> RegexType -> WithCaptures -> m (Macros r) Source #

generate the standard prelude Macros used to parse REs

preludeMacroTable :: RegexType -> String Source #

format the standard prelude macros in a markdown table

preludeMacroSummary :: RegexType -> PreludeMacro -> String Source #

generate a textual summary of the prelude macros

preludeMacroSources :: RegexType -> String Source #

generate a plain text table giving the RE for each macro with all macros expanded (to NF)

preludeMacroSource :: RegexType -> PreludeMacro -> String Source #

generate plain text giving theexpanded RE for a single macro

preludeMacroEnv :: RegexType -> MacroEnv Source #

generate the MacroEnv for the standard prelude macros