This is a follow-up on a long journey where I've pulled my hair out extracting text from parsing GLSL shader files using regex in C++11 with VS 2013 rc5.
Here is the intendant result:
The C++ equivalent looks like this, which is a copycat of the PHP version:
std::smatch u;
std::string s = l_shader->GetData();
std::smatch u;
std::regex_search(s.cbegin(), s.cend(), u, std::regex("<(\\S+)[!]>([.*\\s*\\S*]*?)<[!]\\S+>"));
Unfortunately, std::regex_search doesn't return any results. I've been banging my head trying to figure it out. What am I missing?
Aucun commentaire:
Enregistrer un commentaire