ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/repos/Matcher/Menes/Matcher.cpp
(Generate patch)

Comparing Matcher/Menes/Matcher.cpp (file contents):
Revision 319 by douglas, 2004-12-13T16:06:07-08:00 vs.
Revision 324 by douglas, 2004-12-13T19:40:34-08:00

# Line 18 | Line 18 | bool Matcher::match(const ext::String& s
18          {
19                  int length;
20  
21 <                pcre_fullinfo(expression, NULL, PCRE_INFO_CAPTURECOUNT, &length);
21 >                ::pcre_fullinfo(expression, NULL, PCRE_INFO_CAPTURECOUNT, &length);
22  
23 <                int* substrings(new int[(++length *= 3)]);
24 <                int count(pcre_exec(expression, NULL, stuff.GetData().Begin(), stuff.GetData().GetSize(), 0, 0, substrings, length));
23 >                int* substrings(new int[++length *= 3]), count(::pcre_exec(expression, NULL, stuff.GetData().Begin(), stuff.GetData().GetSize(), 0, 0, substrings, length));
24  
25                  if (count > 0)
26                  {
# Line 29 | Line 28 | bool Matcher::match(const ext::String& s
28  
29                          for (int index(0); index < count; ++index)
30                          {
31 <                                pcre_copy_substring(stuff.GetData().Begin(), substrings, count, index, substring, stuff.GetData().GetSize() + 1);
31 >                                ::pcre_copy_substring(stuff.GetData().Begin(), substrings, count, index, substring, stuff.GetData().GetSize() + 1);
32  
33                                  this->substrings.InsertLast(substring);
34                          }
# Line 50 | Line 49 | Matcher& Matcher::operator()(const ext::
49   {
50          substrings.Clear();
51  
52 <        if (this->expression != NULL) pcre_free(this->expression);
52 >        if (this->expression != NULL) ::pcre_free(this->expression);
53  
54          const char* error;
55          int offset;
56  
57 <        this->expression = pcre_compile(expression.NullTerminate(), PCRE_MULTILINE, &error, &offset, NULL);
57 >        this->expression = ::pcre_compile(expression.NullTerminate(), PCRE_MULTILINE, &error, &offset, NULL);
58  
59          return *this;
60   }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines