From: Robert Roessler <roessler@rftp.com>
To: Caml-list <caml-list@inria.fr>
Subject: Re: [Caml-list] ANNOUNCE: LablPCRE 0.9 - a PCRE binding for Objective Caml
Date: Thu, 29 Dec 2005 12:44:00 -0800 [thread overview]
Message-ID: <43B44A90.5070304@rftp.com> (raw)
In-Reply-To: <20051229152113.GA29493@phauna.org>
N. Owen Gunden wrote:
> On Thu, Dec 22, 2005 at 09:42:30PM -0800, Robert Roessler wrote:
>> The second public release of the LablPCRE OCaml binding for PCRE is
>> now available, featuring a new "module" interface with expanded
>> functionality and supporting PCRE releases 6.1 - 6.4 (current).
>
> What is the advantage of your PCRE bindings over Markus Mottl's
> pcre-ocaml? How do they differ?
At the time (mid-June 2005), Markus' package would not build properly
on Windows... he invited me to contribute a fix, and in good open
source style, I built my own. ;)
As I was already familiar with PCRE in its "POSIX" interface guise, I
was looking for a relatively simple interface... I found the sheer
comprehensiveness of Markus' binding (giving access to *all* of PCRE)
daunting. So, deciding that others with modest pattern-matching needs
might also appreciate a simpler interface, I built LablPCRE (certainly
not as a replacement, but as a small-footprint alternative).
There are really only three "major" functions in LablPCRE: regcomp to
compile REs, regexec to test them against input, and regmatch when all
that is needed is a simple match/nomatch query (this last is my own
low-resource-consumption addition - it is not included in the POSIX API).
In addition, of course, there are a handful of functions for accessing
the match state, errors, and/or any captured substrings from a regexec
invocation. Some effort is made to make a Pcre.t value as light as
possible, e.g., a reference to the tested string will only be kept if
the match succeeded *and* substring capture was requested.
The original release made the above (minus regmatch) available in an
"object" form... subsequent experience with OCaml vernacular and idiom
suggested that a "module" interface was superior, so the current
release has been re-oriented to that style (with the original object
interface still available).
> Is there API documentation for your library on the web somewhere?
Yes - in the LablPCRE-0.9.tar.gz file on the download site. :)
As seems to be somewhat common in the OCaml world, there is a
commented .mli file, and a README.txt with more in-depth discussions
and examples.
Robert Roessler
roessler@rftp.com
http://www.rftp.com
next prev parent reply other threads:[~2005-12-29 20:43 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-12-23 5:42 Robert Roessler
2005-12-29 15:21 ` [Caml-list] " N. Owen Gunden
2005-12-29 20:44 ` Robert Roessler [this message]
2005-12-30 15:04 ` Christoph Bauer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=43B44A90.5070304@rftp.com \
--to=roessler@rftp.com \
--cc=caml-list@inria.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox