package re
Legend:
Library
Module
Module type
Parameter
Class
Class type
Library
Module
Module type
Parameter
Class
Class type
References:
Example of how to use this module (to parse some IRC logs):
type msg = {
time:string;
author:string;
content:string;
}
let re = Core.compile (Re_posix.re "([^:].*:[^:]*:[^:]{2})<.([^>]+)> (.+)$")
(* parse a line *)
let match_line line =
try
let substrings = Core.exec re line in
let groups = Core.get_all substrings in
(* groups can be obtained directly by index within [substrings] *)
Some {time=groups.(1); author=groups.(2); content=groups.(3)}
with Not_found ->
None (* regex didn't match *)
val re : ?opts:opt list -> string -> Re__.Core.t
Parsing of a Posix extended regular expression
val compile_pat : ?opts:opt list -> string -> Re__.Core.re
compile_pat ?opts regex
compiles the Posix extended regular expression regexp
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>