2 .\" Copyright (C), 1995, Graeme W. Wilford. (Wilf.)
4 .\" SPDX-License-Identifier: Linux-man-pages-copyleft
6 .\" Wed Jun 14 16:10:28 BST 1995 Wilf. (G.Wilford@@ee.surrey.ac.uk)
8 .TH re_comp 3 (date) "Linux man-pages (unreleased)"
10 re_comp, re_exec \- BSD regex functions
13 .RI ( libc ", " \-lc )
16 .B #define _REGEX_RE_COMP
17 .B #include <sys/types.h>
20 .BI "[[deprecated]] char *re_comp(const char *" regex );
21 .BI "[[deprecated]] int re_exec(const char *" string );
25 is used to compile the null-terminated regular expression pointed to by
27 The compiled pattern occupies a static area, the pattern buffer,
28 which is overwritten by subsequent use of
33 no operation is performed and the pattern buffer's contents are not
37 is used to assess whether the null-terminated string pointed to by
39 matches the previously compiled
43 returns NULL on successful compilation of
45 otherwise it returns a pointer to an appropriate error message.
48 returns 1 for a successful match, zero for failure.
50 For an explanation of the terms used in this section, see
58 Interface Attribute Value
62 T} Thread safety MT-Unsafe
72 These functions are obsolete; the functions documented in
74 should be used instead.