diff options
author | Steve Bennett <steveb@workware.net.au> | 2014-01-11 21:13:16 +1000 |
---|---|---|
committer | Steve Bennett <steveb@workware.net.au> | 2014-01-21 16:10:19 +1000 |
commit | fcfb8169cfa5fefe5610bcc4297500ead2dfaf42 (patch) | |
tree | 01f5b859d134e7f164a3b6935bffe9607d6fb05b /jimregexp.h | |
parent | 30a78d4c698c3d47ecf2d399cd553d9e4340c788 (diff) | |
download | jimtcl-fcfb8169cfa5fefe5610bcc4297500ead2dfaf42.zip jimtcl-fcfb8169cfa5fefe5610bcc4297500ead2dfaf42.tar.gz jimtcl-fcfb8169cfa5fefe5610bcc4297500ead2dfaf42.tar.bz2 |
many comment changes, some small code changes
Sweep through and clean up all (most) of the comments in the code.
While there, adjust some variable and function names to be more consistent,
and make a few small code changes - again, mostly for consistency.
Signed-off-by: Steve Bennett <steveb@workware.net.au>
Diffstat (limited to 'jimregexp.h')
-rw-r--r-- | jimregexp.h | 26 |
1 files changed, 9 insertions, 17 deletions
diff --git a/jimregexp.h b/jimregexp.h index 79a87e5..b7598d4 100644 --- a/jimregexp.h +++ b/jimregexp.h @@ -1,27 +1,17 @@ #ifndef JIMREGEXP_H #define JIMREGEXP_H -#ifndef _JIMAUTOCONF_H -#error Need jimautoconf.h -#endif - -#if defined(HAVE_REGCOMP) && !defined(JIM_REGEXP) -/* Use POSIX regex */ -#include <regex.h> +/** regexp(3)-compatible regular expression implementation for Jim. + * + * See jimregexp.c for details + */ -#else +#ifdef __cplusplus +extern "C" { +#endif #include <stdlib.h> -/* - * Definitions etc. for regexp(3) routines. - * - * Caveat: this is V8 regexp(3) [actually, a reimplementation thereof], - * not the System V one. - * - * 11/04/02 (seiwald) - const-ing for string literals - */ - typedef struct { int rm_so; int rm_eo; @@ -112,6 +102,8 @@ int regexec(regex_t *preg, const char *string, size_t nmatch, regmatch_t pmat size_t regerror(int errcode, const regex_t *preg, char *errbuf, size_t errbuf_size); void regfree(regex_t *preg); +#ifdef __cplusplus +} #endif #endif |