Oniguruma.RegSetSourceA set of regular expressions that can be searched simultaneously.
create regexes creates a regex set from regexes.
Ownership of regex internals is transferred to the regset (matching Oniguruma's C API). After creating the regset, use the set for searching instead of reusing those regex values directly.
val search :
t ->
string ->
int ->
int ->
Options.search_time Options.t ->
(int * Region.t) optionsearch set string start range options searches string for the leftmost match across all regexes in set using ONIG_REGSET_POSITION_LEAD.
Returns Some (idx, region) where idx is the 0-based index of the matched regex from the array passed to create. Returns None on mismatch. Raises Error on other Oniguruma errors.