diff options
author | Paul Wankadia <junyer@google.com> | 2015-04-10 02:28:27 +1000 |
---|---|---|
committer | Paul Wankadia <junyer@google.com> | 2015-04-09 17:32:59 +0000 |
commit | 9a3bcacc4e1fd91ad7c4234a083b7045b273f367 (patch) | |
tree | 2ed86171fe30b48c6211a54289238e3b9a522f1c /re2/re2.h | |
parent | e69f55cbdaa45e9fe5f8e4354146b3126ded2c11 (diff) | |
download | regex-re2-9a3bcacc4e1fd91ad7c4234a083b7045b273f367.tar.gz |
Add missing RE2::Arg constructor.
Fixes #4.
Change-Id: Id5a118cbfb21e5ad2bfc1996093608ba93b9edd8
Reviewed-on: https://code-review.googlesource.com/2240
Reviewed-by: Russ Cox <rsc@swtch.com>
Diffstat (limited to 're2/re2.h')
-rw-r--r-- | re2/re2.h | 9 |
1 files changed, 4 insertions, 5 deletions
@@ -797,12 +797,11 @@ class RE2::Arg { #undef MAKE_PARSER - // Generic constructor - template <class T> Arg(T*, Parser parser); - // Generic constructor template + // Generic constructor templates template <class T> Arg(T* p) - : arg_(p), parser_(_RE2_MatchObject<T>::Parse) { - } + : arg_(p), parser_(_RE2_MatchObject<T>::Parse) { } + template <class T> Arg(T* p, Parser parser) + : arg_(p), parser_(parser) { } // Parse the data bool Parse(const char* str, int n) const; |