20 Jul
2007
20 Jul
'07
7:37 a.m.
Bryan Green writes:
pair
parse_opt(const string& s) { if (s.find("--proxy=") == 0) { return make_pair(string("proxy"), s.substr(8)); } else { return make_pair(string(), string()); } }
This function could of course be made general-purpose, by detecting the '--.*=' pattern. -Bryan