/[pcre]/code/trunk/doc/pcreapi.3
ViewVC logotype

Diff of /code/trunk/doc/pcreapi.3

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 513 by ph10, Mon May 3 11:13:37 2010 UTC revision 525 by ph10, Wed May 26 10:50:24 2010 UTC
# Line 132  an application that uses PCRE. The heade Line 132  an application that uses PCRE. The heade
132  and PCRE_MINOR to contain the major and minor release numbers for the library.  and PCRE_MINOR to contain the major and minor release numbers for the library.
133  Applications can use these to include support for different releases of PCRE.  Applications can use these to include support for different releases of PCRE.
134  .P  .P
135    In a Windows environment, if you want to statically link an application program
136    against a non-dll \fBpcre.a\fP file, you must define PCRE_STATIC before
137    including \fBpcre.h\fP, because otherwise the \fBpcre_malloc()\fP and
138    \fBpcre_free()\fP exported functions will be declared
139    \fB__declspec(dllimport)\fP, with unwanted results.
140    .P
141  The functions \fBpcre_compile()\fP, \fBpcre_compile2()\fP, \fBpcre_study()\fP,  The functions \fBpcre_compile()\fP, \fBpcre_compile2()\fP, \fBpcre_study()\fP,
142  and \fBpcre_exec()\fP are used for compiling and matching regular expressions  and \fBpcre_exec()\fP are used for compiling and matching regular expressions
143  in a Perl-compatible manner. A sample program that demonstrates the simplest  in a Perl-compatible manner. A sample program that demonstrates the simplest
# Line 636  were followed by ?: but named parenthese Line 642  were followed by ?: but named parenthese
642  they acquire numbers in the usual way). There is no equivalent of this option  they acquire numbers in the usual way). There is no equivalent of this option
643  in Perl.  in Perl.
644  .sp  .sp
645      PCRE_UCP
646    .sp
647    This option changes the way PCRE processes \eb, \ed, \es, \ew, and some of the
648    POSIX character classes. By default, only ASCII characters are recognized, but
649    if PCRE_UCP is set, Unicode properties are used instead to classify characters.
650    More details are given in the section on
651    .\" HTML <a href="pcre.html#genericchartypes">
652    .\" </a>
653    generic character types
654    .\"
655    in the
656    .\" HREF
657    \fBpcrepattern\fP
658    .\"
659    page. If you set PCRE_UCP, matching one of the items it affects takes much
660    longer. The option is available only if PCRE has been compiled with Unicode
661    property support.
662    .sp
663    PCRE_UNGREEDY    PCRE_UNGREEDY
664  .sp  .sp
665  This option inverts the "greediness" of the quantifiers so that they are not  This option inverts the "greediness" of the quantifiers so that they are not
# Line 756  out of use. To avoid confusion, they hav Line 780  out of use. To avoid confusion, they hav
780    64  ] is an invalid data character in JavaScript compatibility mode    64  ] is an invalid data character in JavaScript compatibility mode
781    65  different names for subpatterns of the same number are not allowed    65  different names for subpatterns of the same number are not allowed
782    66  (*MARK) must have an argument    66  (*MARK) must have an argument
783      67  this version of PCRE is not compiled with PCRE_UCP support
784  .sp  .sp
785  The numbers 32 and 10000 in errors 48 and 49 are defaults; different values may  The numbers 32 and 10000 in errors 48 and 49 are defaults; different values may
786  be used if the limits were changed when PCRE was built.  be used if the limits were changed when PCRE was built.
# Line 830  matching. Line 855  matching.
855  PCRE handles caseless matching, and determines whether characters are letters,  PCRE handles caseless matching, and determines whether characters are letters,
856  digits, or whatever, by reference to a set of tables, indexed by character  digits, or whatever, by reference to a set of tables, indexed by character
857  value. When running in UTF-8 mode, this applies only to characters with codes  value. When running in UTF-8 mode, this applies only to characters with codes
858  less than 128. Higher-valued codes never match escapes such as \ew or \ed, but  less than 128. By default, higher-valued codes never match escapes such as \ew
859  can be tested with \ep if PCRE is built with Unicode character property  or \ed, but they can be tested with \ep if PCRE is built with Unicode character
860  support. The use of locales with Unicode is discouraged. If you are handling  property support. Alternatively, the PCRE_UCP option can be set at compile
861  characters with codes greater than 128, you should either use UTF-8 and  time; this causes \ew and friends to use Unicode property support instead of
862  Unicode, or use locales, but not try to mix the two.  built-in tables. The use of locales with Unicode is discouraged. If you are
863    handling characters with codes greater than 128, you should either use UTF-8
864    and Unicode, or use locales, but not try to mix the two.
865  .P  .P
866  PCRE contains an internal set of tables that are used when the final argument  PCRE contains an internal set of tables that are used when the final argument
867  of \fBpcre_compile()\fP is NULL. These are sufficient for many applications.  of \fBpcre_compile()\fP is NULL. These are sufficient for many applications.
# Line 2100  Cambridge CB2 3QH, England. Line 2127  Cambridge CB2 3QH, England.
2127  .rs  .rs
2128  .sp  .sp
2129  .nf  .nf
2130  Last updated: 03 May 2010  Last updated: 26 May 2010
2131  Copyright (c) 1997-2010 University of Cambridge.  Copyright (c) 1997-2010 University of Cambridge.
2132  .fi  .fi

Legend:
Removed from v.513  
changed lines
  Added in v.525

  ViewVC Help
Powered by ViewVC 1.1.5