1234567891011
static string searchFunc(string a, string b){ ifstream inp; inp.open(a, std::ios::in); string c; std::tr1::cmatch res; std::tr1::regex rx(b); while(getline(inp,c)){ std::tr1::regex_match(c.c_str(), res, rx); } return res; }