package oniguruma

  1. Overview
  2. Docs
Bindings to the Oniguruma regular expression library

Install

dune-project
 Dependency

Authors

Maintainers

Sources

oniguruma-0.1.2.tbz
sha256=e3f63ffdda3cc3cf9f71a8169e8fb97690026dbd22ab7ce0a87891feb8058765
sha512=4d8561b50bf13a792d05d2ac775948ab6f913730202c40012aa1ac7caf5a2f2aba26f7e1dcb3f93528e2be79602fd26de62346bec7d8986d9c48efdb71f94409

doc/oniguruma/Oniguruma/Region/index.html

Module Oniguruma.RegionSource

Match results.

Sourcetype t

The capture groups returned by a search or match.

Sourceval length : t -> int

length region gets the number of captures.

Sourceval capture_beg : t -> int -> int

capture_beg region idx gets the string position of the capture at the index. The capture at index 0 is the entire match. The string position is an offset in bytes. Returns -1 if the capture group wasn't found. Raises Invalid_argument if the index is out of bounds.

Sourceval capture_end : t -> int -> int

capture_end region idx gets the string position of the capture at the index. The capture at index 0 is the entire match. The string position is an offset in bytes. Returns -1 if the capture group wasn't found. Raises Invalid_argument if the index is out of bounds.