13 Feb
2015
13 Feb
'15
3:09 a.m.
Hi, the following regex expression works in perl-mode, but does not work in extented-mode. What's the reason? I think I haven't used any perl-specific construct, or did I? Where? ... #define NUM "[+-]?(\\d+\\.?\\d*|\\.\\d+)([eE][+-]?\\d+)?" #define WORD "[\\w\\-\\.~/]+" #define EQU "\\s*\\=\\s*" const string sUserRE_VarAndVal = WORD EQU NUM; #if 0 #define REGEX_ENGINE boost::regex::extended #else #define REGEX_ENGINE boost::regex::perl #endif regex reNum(sUserRE_VarAndVal, REGEX_ENGINE); ...