Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Ko__Ronny
Novice
115 Views

Using the regular expression library in SGX

Hi,
I am trying to use regular expressions in my SGX app and in SGX v2.5 I can include the regex header file by doing "#include <regex>". However, I cannot compile the program that looks like the following:

int main() 
{ 
    string a = "GeeksForGeeks"; 
  
    // Here b is an object of regex (regular expression) 
    regex b("(Geek)(.*)"); // Geeks followed by any character 
  
    // regex_match function matches string a against regex b 
    if ( regex_match(a, b) ) 
        cout << "String 'a' matches regular expression 'b' \n"; 
  
    // regex_match function for matching a range in string  
    // against regex b 
    if ( regex_match(a.begin(), a.end(), b) ) 
        cout << "String 'a' matches with regular expression "
                "'b' in the range from 0 to string end\n"; 
  
    return 0; 
} 

The compiler says regex is not defined. I wonder if regex is not being supported in SGX, yet.

 

Ronny

 

0 Kudos
0 Replies
Reply