package ochre

  1. Overview
  2. Docs
Syntax highlighter using TextMate grammars and themes

Install

dune-project
 Dependency

Authors

Maintainers

Sources

ochre-1.0.0.tbz
sha256=820412863edca3173c7365cf16b4b4bad41c8fffbb4bfba8f0d87a40d4ad525b
sha512=f8a16876281504e714fe465df8a1a9894a90f06fc6cead07534722c0aa83abf955d9951e66549ac78a016e27fe8cdc5596f415e26f1c5309ee893722078f56ae

doc/ochre.oniguruma/Oniguruma/RegSet/index.html

Module Oniguruma.RegSetSource

Sourcetype t

A set of regular expressions that can be searched simultaneously.

Sourceval create : _ regex array -> t

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.

search 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.