summaryrefslogtreecommitdiff
path: root/pcrecpp.h
diff options
context:
space:
mode:
authorph10 <ph10@2f5784b3-3f2a-0410-8824-cb99058d5e15>2008-01-21 14:57:19 +0000
committerph10 <ph10@2f5784b3-3f2a-0410-8824-cb99058d5e15>2008-01-21 14:57:19 +0000
commit4ff532b445e64eb6453bccb24a8e23a6831488ea (patch)
treed90370614d145b71f207f30bf5873c8fb1772d4e /pcrecpp.h
parent1d4f53aa517fc898d563c40cd36243653547177c (diff)
downloadpcre-4ff532b445e64eb6453bccb24a8e23a6831488ea.tar.gz
Apply Craig's patch to move no_arg into the RE class.
git-svn-id: svn://vcs.exim.org/pcre/code/trunk@308 2f5784b3-3f2a-0410-8824-cb99058d5e15
Diffstat (limited to 'pcrecpp.h')
-rw-r--r--pcrecpp.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/pcrecpp.h b/pcrecpp.h
index 646b999..a4638e1 100644
--- a/pcrecpp.h
+++ b/pcrecpp.h
@@ -346,9 +346,6 @@ namespace pcrecpp {
#define PCRE_IS_SET(o) \
(all_options_ & o) == o
-// We convert user-passed pointers into special Arg objects
-PCRECPP_EXP_DECL Arg no_arg;
-
/***** Compiling regular expressions: the RE class *****/
// RE_Options allow you to set options to be passed along to pcre,
@@ -403,25 +400,25 @@ class PCRECPP_EXP_DEFN RE_Options {
return PCRE_IS_SET(PCRE_DOTALL);
}
RE_Options &set_dotall(bool x) {
- PCRE_SET_OR_CLEAR(x,PCRE_DOTALL);
+ PCRE_SET_OR_CLEAR(x, PCRE_DOTALL);
}
bool extended() const {
return PCRE_IS_SET(PCRE_EXTENDED);
}
RE_Options &set_extended(bool x) {
- PCRE_SET_OR_CLEAR(x,PCRE_EXTENDED);
+ PCRE_SET_OR_CLEAR(x, PCRE_EXTENDED);
}
bool dollar_endonly() const {
return PCRE_IS_SET(PCRE_DOLLAR_ENDONLY);
}
RE_Options &set_dollar_endonly(bool x) {
- PCRE_SET_OR_CLEAR(x,PCRE_DOLLAR_ENDONLY);
+ PCRE_SET_OR_CLEAR(x, PCRE_DOLLAR_ENDONLY);
}
bool extra() const {
- return PCRE_IS_SET( PCRE_EXTRA);
+ return PCRE_IS_SET(PCRE_EXTRA);
}
RE_Options &set_extra(bool x) {
PCRE_SET_OR_CLEAR(x, PCRE_EXTRA);
@@ -646,6 +643,9 @@ class PCRECPP_EXP_DEFN RE {
// regexp wasn't valid on construction.
int NumberOfCapturingGroups() const;
+ // The default value for an argument, to indicate no arg was passed in
+ static Arg no_arg;
+
private:
void Init(const string& pattern, const RE_Options* options);