Improve error message for invalid field accesses

fixes #8079
This commit is contained in:
Gunnar Beutner 2014-12-20 09:17:02 +01:00
parent 3e64b642ca
commit 6fddec0dd3
1 changed files with 1 additions and 1 deletions

View File

@ -139,7 +139,7 @@ public:
return intrusive_ptr<T>(); return intrusive_ptr<T>();
if (!IsObject()) if (!IsObject())
BOOST_THROW_EXCEPTION(std::runtime_error("Cannot convert value to object.")); BOOST_THROW_EXCEPTION(std::runtime_error("Cannot convert value of type '" + GetTypeName() + "' to an object."));
Object::Ptr object = boost::get<Object::Ptr>(m_Value); Object::Ptr object = boost::get<Object::Ptr>(m_Value);