Commit 6e90cced authored by Max Lyon's avatar Max Lyon

allow to force static casts when requesting properties

parent 41b6662b
Pipeline #258 passed with stage
......@@ -96,8 +96,12 @@ PropT ResourceManager::request_property(StdVecT& _vec, const std::string& _name,
for(typename StdVecT::iterator it = _vec.begin();
it != _vec.end(); ++it) {
if((*it)->name() == _name) {
#if OVM_FORCE_STATIC_CAST
return *static_cast<PropT*>(*it);
#else
PropT* prop = dynamic_cast<PropT*>(*it);
if(prop != NULL) return *prop;
#endif
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment