OCamlregextkit is a library providing simple interface to operations on regular expressions, NFAs, and DFAs.
Written in OCaml, using the Dune build system.
Requires
See OCaml docs for installation instructions.
Find documentation for the toolkit here
Note: all modules are packaged into a single module Regextkit
For demonstration purposes, demo
is a program built using the toolkit which accepts two regular expressions on the command line, and either verifies that they are equivalent or prints a word that matches one expression but not the other.
make
cd demo
make
dune exec ./demo.exe "<regex>" "<regex>"
To test the demo, run
make test
This will run a set of test cases, which checks correctness of basic parsing, equivalence, and difference of two regular expressions.
The testing
directory contains code to profile and run timing tests for equivalence and minimisation of DFAs.
Run make profile
or make test
to compile and execute the respective function.
make
Builds the library with dunemake clean
Removes dune's build directorymake doc
Generates documentation for the toolkit