The witness function in core.ml can generate strings that don't match the expression, because it ignores the semantics of things like eow. Minimal example:
let t = Re.seq [ Re.eow; Re.str "foo" ] in
let witness = Re.witness t in
assert (not (Re.execp (Re.compile t) witness)) (* assertion succeeds but shouldn't *)
(For me personally this is low priority since I don't need that function. I just happened to notice it looked buggy.)
The
witnessfunction in core.ml can generate strings that don't match the expression, because it ignores the semantics of things likeeow. Minimal example:(For me personally this is low priority since I don't need that function. I just happened to notice it looked buggy.)