A library to defines a structure of regular expressions and a simple match operation for regular expressions. This library is used to translate integrated code in the form of POSIX extended regular expressions into Curry programs.
Author: Jasper Sikorra
Version: November 2020
match
:: Ord a => [ORegExp a] -> [a] -> Bool
The match function is used to match lists with regular expressions |
Data type for regex representation in Curry
Type synonym: RegExp a = [ORegExp a]
Constructors:
Nil
:: ORegExp a
Literal
:: a -> ORegExp a
Xor
:: (RegExp a) -> (RegExp a) -> ORegExp a
Star
:: (RegExp a) -> ORegExp a
Plus
:: (RegExp a) -> ORegExp a
AnyLiteral
:: ORegExp a
Bracket
:: [Either a (a,a)] -> ORegExp a
NegBracket
:: [Either a (a,a)] -> ORegExp a
Start
:: (RegExp a) -> ORegExp a
End
:: (RegExp a) -> ORegExp a
Times
:: (Int,Int) -> (RegExp a) -> ORegExp a