- std::cerr << "The settings file " << filePath <<
- " does not contain any valid settings." << std::endl;
+ serializable_ptr obj = in.deserialize();
+ std::map<std::string,serializable_ptr> dict;
+ if (obj && obj->get(dict))
+ {
+ if (!precedence)
+ {
+ map.insert(dict.begin(), dict.end());
+ }
+ else
+ {
+ dict.insert(map.begin(), map.end());
+ map = dict;
+ }
+ }
+ }
+ catch (deserializer::exception e)
+ {
+ std::cerr << "Cannot load settings from " << *it <<
+ " because an exception was thrown: " << e.what() << std::endl;