
08.02.2011 12:37, Ilya Sokolov пишет:
On Tue, 08 Feb 2011 12:50:59 +0500, Denis Shevchenko <for.dshevchenko@gmail.com> wrote:
Of course, with boost::assign ;-)
-1. No need to add a dependency in such simple case
Hm... Dependency from widely used header-only library? So what? Is it problem?
[snip]
6. In function boost::process::self::get_environment().
environment e; // ... try { char *env = ms_environ; while (*env) { std::string s = env; std::string::size_type pos = s.find('='); e.insert(environment::value_type(s.substr(0, pos), s.substr(pos + 1))); env += s.size() + 1; } } catch (...) { // ... }
And what kind of exceptions can occur here? std::string::find, std::string::substr, std::map::insert, std::string::operator+= std::string::size these functions do not throw exceptions...
???
In 'try scope' placed code that never throws... - Denis