Open System Services Library Calls Reference Manual (G06.28+, H06.05+)

OSS Library Calls (n - r) regcomp(3)
pat- |
tern
Contains the basic or extended regular expression to be compiled by regcomp().|
The default regular expression type for the pattern parameter is a basic regular |
expression. An application can specify extended regular expressions with the |
REG_EXTENDED ag. If the REG_NOSUB ag is not set in the cags |
parameter, the regcomp() function sets the number of parenthetic subexpres- |
sions (delimited by a \( (backslash left parenthesis) and \) (backslash right |
parenthesis) pair in basic regular expressions, or ( ) (parentheses) in extended |
regular expressions) to the number found in the pattern parameter. |
preg ||
The structure that contains the compiled basic or extended regular expression. |
errcode ||
Identies the error code. |
errbuf ||
Points to the buffer where regerror() stores the message text. |
errbuf_size ||
Species the size of the errbuf buffer. |
string ||
Contains the data to be matched. |
nmatch ||
Contains the number of subexpressions to match. |
pmatch ||
Contains the array of offsets into the string parameter that match the correspond- |
ing subexpression in the preg parameter. |
eflags ||
Contains the bitwise inclusive OR of zero or more of the ags controlling the |
customizable behavior of the regexec function. |
The eags parameter modies the interpretation of the contents of the string |
parameter. The value for this parameter is formed by bitwise inclusive ORing |
zero or more of the following ags, which are dened in the |
/usr/include/regex.h le. |
REG_NOTBOL ||
The rst character of the string pointed to by the string parameter is not the beginning |
of the line. Therefore, the circumex character ˆ (circumex), when taken as a special |
character, does not match the beginning of the string parameter. |
REG_NOTEOL ||
The last character of the string pointed to by the string parameter is not the end of the |
line. Therefore, the $ (dollar sign), when taken as a special character, does not match |
the end of the string parameter. |
527187-007 Hewlett-Packard Company 591