{
public:
inline Value(void)
- : m_Value()
{ }
inline Value(int value)
{ }
inline Value(Object *value)
- : m_Value()
{
if (!value)
return;
template<typename T>
inline Value(const intrusive_ptr<T>& value)
- : m_Value()
{
if (!value)
return;
*/
inline bool IsEmpty(void) const
{
- return (GetType() == ValueEmpty);
+ return (GetType() == ValueEmpty || (IsString() && boost::get<String>(m_Value).IsEmpty()));
}
/**
Value value = VMOps::GetField(object, require);
- if (value.IsEmpty() || (value.IsString() && static_cast<String>(value).IsEmpty()))
+ if (value.IsEmpty())
BOOST_THROW_EXCEPTION(ScriptError("Required attribute is missing: " + LocationToString(locations)));
locations.pop_back();