|2022-05-15||posix-regex.egg: Compile with -O3 by default||Sören Tempel|
|2022-04-22||README.md: Fix markup||Sören Tempel|
|2022-03-19||Remove unneeded begin expression||Sören Tempel|
|2022-03-17||Update referenced version of regex Open Group HTML||Sören Tempel|
|2022-03-17||Re-add documentation for first element of submatch vector||Sören Tempel|
Clone the repository to access all 42 commits.
CHICKEN egg for POSIX regular expressions supporting POSIX EREs and BREs.
CHICKEN’s default regex library only supports POSIX EREs with PCRE extensions.
Unfourtunatly, I needed a strict POSIX-compliant BRE implementation, without any extensions, for my implementation of the ed text editor in CHICKEN Scheme.
For this reason, I originally used CHICKEN’s Foreign Function Interface to use the POSIX
regexec(3) functions directly in the codebase of my editor.
However, the code for wrapping these functions became more complex over time (e.g. due to support for better error messages via
As such, I decided to move it to a dedicated library which may be useful for other CHICKEN Schemers which are looking for a pure POSIX BRE or ERE implementation.
- Thin wrappers for
- Error handling via R7RS exceptions and a
- API with strict CHICKEN type annotations
- Support for submatches via R7RS bytevectors
This library is available in the CHICKEN egg repository and can be installed using:
$ chicken-install posix-regex
The documentation is maintained separately in the CHICKEN wiki.
Initially, the documentation was partially generated with schematic from inline comments using:
$ schematic-wiki -c ';;>' < posix-regex.scm
For an elaborate usage example, refer to the source code of the edward text editor.
This library is licensed under GPL-3.0-only.