each macro can reference others, the whole environment being required for each macro, so we use a Lazy HashMap
Moduleregex-1.1.0.2Haskell2010
Text.RE.TestBench
- 6 types
- 12 values
- Packageregex-1.1.0.2
- Exports18
- LanguageHaskell2010
- LicenceBSD-3-Clause
- SourceTestBench.lhs
The Test Bench Tutorial
0 declarationsThis API module provides a test bench for developing, documenting and testing regex RE macros.
See the tutorials at http://re-tutorial-testbench.regex.uk
The Test Bench
8 declarationsdescribes a macro, giving the text of the RE and a summary description
Constructors
MacroDescriptormacroSource :: !RegexSourcethe RE
macroSamples :: ![String]some sample matches
macroCounterSamples :: ![String]some sample non-matches
macroTestResults :: ![TestResult]validation test results
macroParser :: !Maybe FunctionIDWA, the parser function
macroDescription :: !Stringsummary comment
Instances1Show
Show MacroDescriptorDefined in regex-1.1.0.2 · Text.RE.ZeInternals.TestBench
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
Instances2Show, IsString
Show RegexSourceDefined in regex-1.1.0.2 · Text.RE.ZeInternals.TestBenchIsString RegexSourceDefined in regex-1.1.0.2 · Text.RE.ZeInternals.TestBench
do we need the captures in the RE or would they be stripped out where possible
Constructors
InclCapturesinclude all captures
ExclCapturesremove captures where possible
Instances3Eq, Ord, Show
Eq WithCapturesDefined in regex-1.1.0.2 · Text.RE.ZeInternals.TestBenchOrd WithCapturesDefined in regex-1.1.0.2 · Text.RE.ZeInternals.TestBenchShow WithCapturesDefined in regex-1.1.0.2 · Text.RE.ZeInternals.TestBench
what flavour of regex are we dealing with
test RegexType for TDFA/PCREness
test RegexType for TDFA/PCREness
Constructing a MacrosEnv
construct a macro table suitable for use with the RE compilers
Formatting Macros
format a macros table as a markdown table
generate a plain text summary of a macro
list the source REs for each macro in plain text
list the source of a single macro in plain text
Formatting Macros
test that a MacroEnv is passing all of its built-in tests
The Parsers
0 declarationsmodule Text.RE.TestBench.Parsers
The Match Type
1 declarationthe result of matching a RE to a text once (with ?=~), retaining
the text that was matched against
Instances4Functor, RegexContext, Eq, Show
Functor MatchDefined in regex-1.1.0.2 · Text.RE.ZeInternals.Types.Match(RegexContext regex source (AllTextSubmatches (Array Int) (source, (Int, Int))), RegexLike regex source, RegexFix regex source) => RegexContext regex source (Match source)Defined in regex-1.1.0.2 · Text.RE.ZeInternals.Types.Matchthis instance hooks Match into regex-base: regex consumers need not worry about any of this
Eq a => Eq (Match a)Defined in regex-1.1.0.2 · Text.RE.ZeInternals.Types.MatchShow a => Show (Match a)Defined in regex-1.1.0.2 · Text.RE.ZeInternals.Types.Match