Merge pull request #9 from wichtounet/no_rtti

Macro to disable RTTI
This commit is contained in:
jarro2783 2014-10-30 07:55:19 +11:00
commit 1bf66a40ff

View File

@ -500,7 +500,11 @@ namespace cxxopts
const T&
as() const
{
#ifdef CXXOPTS_NO_RTTI
return static_cast<const values::default_value<T>&>(*m_value).get();
#else
return dynamic_cast<const values::default_value<T>&>(*m_value).get();
#endif
}
private: