@@ -82,8 +82,8 @@ void ofApp::keyPressed(int _key){
8282}
8383
8484string ofApp::grepStringInRegex (string _str, string _reg){
85- smatch match;
86- regex regEx (_reg, regex_constants::icase);
85+ std:: smatch match;
86+ std:: regex regEx (_reg, std:: regex_constants::icase);
8787
8888 stringstream buffer;
8989 while (regex_search (_str,match,regEx)) {
@@ -96,15 +96,15 @@ string ofApp::grepStringInRegex(string _str, string _reg){
9696}
9797
9898int ofApp::countOccurencesInRegex (string _str, string _reg){
99- regex regEx (_reg, regex_constants::icase);
100- auto wordsBegin = sregex_iterator (_str.begin (), _str.end (), regEx);
101- auto wordsEnd = sregex_iterator ();
99+ std:: regex regEx (_reg, std:: regex_constants::icase);
100+ auto wordsBegin = std:: sregex_iterator (_str.begin (), _str.end (), regEx);
101+ auto wordsEnd = std:: sregex_iterator ();
102102 return distance (wordsBegin, wordsEnd);
103103};
104104
105105bool ofApp::isKeyInRegex (int keyPressed, string _reg){
106106 string typedKey (1 , keyPressed);
107- regex regEx (_reg, regex_constants::icase);
107+ std:: regex regEx (_reg, std:: regex_constants::icase);
108108 if (regex_match (typedKey, regEx)) {
109109 return true ;
110110 } else {
@@ -113,13 +113,13 @@ bool ofApp::isKeyInRegex(int keyPressed, string _reg){
113113}
114114
115115vector<string> ofApp::matchesInRegex (string _str, string _reg){
116- regex regEx (_reg, regex_constants::icase);
116+ std:: regex regEx (_reg, std:: regex_constants::icase);
117117 vector<string> results;
118- auto wordsBegin = sregex_iterator (_str.begin (), _str.end (), regEx);
119- auto wordsEnd = sregex_iterator ();
118+ auto wordsBegin = std:: sregex_iterator (_str.begin (), _str.end (), regEx);
119+ auto wordsEnd = std:: sregex_iterator ();
120120
121121 for (std::sregex_iterator i = wordsBegin; i != wordsEnd; ++i){
122- smatch m = *i;
122+ std:: smatch m = *i;
123123 results.push_back (m.str ());
124124 }
125125 return results;
0 commit comments