Regex #
Definitions for Regex api
@[reducible, inline]
Equations
- Regex.ValidPos s = { pos : String.Pos // String.Pos.Valid s pos }
 
Instances For
Equations
- Regex.instCoeStringValidSubstring = { coe := fun (s : String) => ⟨s.toSubstring, ⋯⟩ }
 
@[reducible, inline]
Represents a single match of a regex in a haystack.
Equations
Instances For
Equations
- One or more equations did not get rendered due to their size.
 
Represents the full match and capture groups for a single match in s.
- fullMatch : Match
the full match
 the capture groups, empty groups can arise, for example, in alternatives
fullMatchis a substring ofs.- areSubstringsOf : (self.groups.all fun (x : Option Match) => Option.all (fun (x : Match) => decide (x.val.str = s)) x) = true
all matches in
groupsare substrings ofs.