X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=regex.h;h=1818d5f9681e03b90dfb7255afd6bc487ac555e1;hb=0add61f27e382ba01fe2c65ef13ebfd484c5ba78;hp=46f2a633c3a614fcecdd529d4989e65b847c2b59;hpb=2f3b372db2163e9ebc7afe5c2ba36b10f4f78514;p=gnulib.git diff --git a/regex.h b/regex.h index 46f2a633c..1818d5f96 100644 --- a/regex.h +++ b/regex.h @@ -150,6 +150,17 @@ typedef unsigned long int reg_syntax_t; /* If this bit is set, then (?:...) is treated as a shy group. */ #define RE_SHY_GROUPS (RE_FRUGAL << 1) +/* If this bit is set, ^ and $ only match at beg/end of buffer. */ +#define RE_NO_NEWLINE_ANCHOR (RE_SHY_GROUPS << 1) + +/* If this bit is set, turn on internal regex debugging. + If not set, and debugging was on, turn it off. + This only works if regex.c is compiled -DDEBUG. + We define this bit always, so that all that's needed to turn on + debugging is to recompile regex.c; the calling code can always have + this bit set, and it won't affect anything in the normal case. */ +#define RE_DEBUG (RE_NO_NEWLINE_ANCHOR << 1) + /* This global variable defines the particular regexp syntax to use (for some interfaces). When a regexp is compiled, the syntax used is stored in the pattern buffer, so changing this does not affect @@ -379,9 +390,6 @@ struct re_pattern_buffer /* Similarly for an end-of-line anchor. */ unsigned not_eol : 1; - /* If true, an anchor at a newline matches. */ - unsigned newline_anchor : 1; - #ifdef emacs /* If true, multi-byte form in the `buffer' should be recognized as a multibyte character. */ @@ -527,10 +535,12 @@ extern int re_exec _RE_ARGS ((const char *)); # endif # endif #endif -/* For now unconditionally define __restrict_arr to expand to nothing. +/* For now conditionally define __restrict_arr to expand to nothing. Ideally we would have a test for the compiler which allows defining it to restrict. */ -#define __restrict_arr +#ifndef __restrict_arr +# define __restrict_arr +#endif /* POSIX compatibility. */ extern int regcomp _RE_ARGS ((regex_t *__restrict __preg, @@ -561,3 +571,6 @@ version-control: t trim-versions-without-asking: nil End: */ + +/* arch-tag: bda6e3ec-3c02-4237-a55a-01ad2e120083 + (do not change this comment) */