HORIZON HASKELLDocslts/ghc-10.0.x8fef28d2026-11-02Search packagesCtrl K
Theme: |

GHC 10.0.0.20260917 · lts/ghc-10.0.x · 8fef28d · 2026-11-02

  • Packageregex-1.1.0.2
  • Exports18
  • LanguageHaskell2010
  • LicenceBSD-3-Clause
  • SourceTestBench.lhs

The Test Bench Tutorial

This 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

describes a macro, giving the text of the RE and a summary description

Constructors

Instances1Show
newtypenewtype RegexSource

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

Instances2Show, IsString
datadata RegexType

what flavour of regex are we dealing with

Instances1Show
  • Show RegexTypeDefined in regex-1.1.0.2 · Text.RE.ZeInternals.TestBench

Constructing a MacrosEnv

Formatting Macros

Formatting Macros

The Parsers

The Match Type

datadata Match a

the 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.Match

    this 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.Match
  • Show a => Show (Match a)Defined in regex-1.1.0.2 · Text.RE.ZeInternals.Types.Match