summaryrefslogtreecommitdiff
path: root/Utilities/PCRE/man/html/pcre_compile.3.html
blob: bd9272c7974015df063c794997b7e9b4aabc05cf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
<!-- manual page source format generated by PolyglotMan v3.2, -->
<!-- available at http://polyglotman.sourceforge.net/ -->

<html>
<head>
<title>PCRE(3) manual page</title>
</head>
<body bgcolor='white'>
<a href='#toc'>Table of Contents</a><p>

<h2><a name='sect0' href='#toc0'>Name</a></h2>
PCRE - Perl-compatible regular expressions 
<h2><a name='sect1' href='#toc1'>Synopsis</a></h2>
 <p>
<b>#include &lt;pcre.h&gt;</b> <p>
<font size='-1'></font>
 <br>
<b>pcre *pcre_compile(const char *<i>pattern</i>, int <i>options</i>,</b>  <b>const char **<i>errptr</i>,
int *<i>erroffset</i>,</b>  <b>const unsigned char *<i>tableptr</i>);</b>  
<h2><a name='sect2' href='#toc2'>Description</a></h2>
 <p>
This function
compiles a regular expression into an internal form. Its arguments are:
<p>
  <i>pattern</i>       A zero-terminated string containing the<br>
                   regular expression to be compiled<br>
   <i>options</i>       Zero or more option bits<br>
   <i>errptr</i>        Where to put an error message<br>
   <i>erroffset</i>     Offset in pattern where error was found<br>
   <i>tableptr</i>      Pointer to character tables, or NULL to<br>
                   use the built-in default<br>
 <p>
The option bits are: <p>
  PCRE_ANCHORED         Force pattern anchoring<br>
   PCRE_AUTO_CALLOUT     Compile automatic callouts<br>
   PCRE_CASELESS         Do caseless matching<br>
   PCRE_DOLLAR_ENDONLY   $ not to match newline at end<br>
   PCRE_DOTALL           . matches anything including NL<br>
   PCRE_EXTENDED         Ignore whitespace and # comments<br>
   PCRE_EXTRA            PCRE extra features<br>
                           (not much use currently)<br>
   PCRE_MULTILINE        ^ and $ match newlines within data<br>
   PCRE_NO_AUTO_CAPTURE  Disable numbered capturing paren-<br>
                           theses (named ones available)<br>
   PCRE_UNGREEDY         Invert greediness of quantifiers<br>
   PCRE_UTF8             Run in UTF-8 mode<br>
   PCRE_NO_UTF8_CHECK    Do not check the pattern for UTF-8<br>
                           validity (only relevant if<br>
                           PCRE_UTF8 is set)<br>
 <p>
PCRE must be built with UTF-8 support in order to use PCRE_UTF8 and PCRE_NO_UTF8_CHECK.
<p>
The yield of the function is a pointer to a private data structure that
contains the compiled pattern, or NULL if an error was detected. <p>
There is
a complete description of the PCRE native API in the  <b>pcreapi</b>  page and
a description of the POSIX API in the  <b>pcreposix</b>  page. <p>

<hr><p>
<a name='toc'><b>Table of Contents</b></a><p>
<ul>
<li><a name='toc0' href='#sect0'>Name</a></li>
<li><a name='toc1' href='#sect1'>Synopsis</a></li>
<li><a name='toc2' href='#sect2'>Description</a></li>
</ul>
</body>
</html>