mirror of
https://github.com/pocoproject/poco.git
synced 2025-10-15 15:16:49 +02:00
clang mac compile
This commit is contained in:
@@ -431,7 +431,7 @@ ValueType AnyCast(const Any& operand)
|
|||||||
/// Some compilers will accept this code although a copy is returned. Use the RefAnyCast in
|
/// Some compilers will accept this code although a copy is returned. Use the RefAnyCast in
|
||||||
/// these cases.
|
/// these cases.
|
||||||
{
|
{
|
||||||
typedef TypeWrapper<ValueType>::TYPE NonRef;
|
typedef typename TypeWrapper<ValueType>::TYPE NonRef;
|
||||||
|
|
||||||
return AnyCast<NonRef&>(const_cast<Any&>(operand));
|
return AnyCast<NonRef&>(const_cast<Any&>(operand));
|
||||||
}
|
}
|
||||||
@@ -448,7 +448,7 @@ ValueType AnyCast(Any& operand)
|
|||||||
/// Some compilers will accept this code although a copy is returned. Use the RefAnyCast in
|
/// Some compilers will accept this code although a copy is returned. Use the RefAnyCast in
|
||||||
/// these cases.
|
/// these cases.
|
||||||
{
|
{
|
||||||
typedef TypeWrapper<ValueType>::TYPE NonRef;
|
typedef typename TypeWrapper<ValueType>::TYPE NonRef;
|
||||||
|
|
||||||
NonRef* result = AnyCast<NonRef>(&operand);
|
NonRef* result = AnyCast<NonRef>(&operand);
|
||||||
if (!result) throw BadCastException("Failed to convert between Any types");
|
if (!result) throw BadCastException("Failed to convert between Any types");
|
||||||
@@ -490,7 +490,7 @@ ValueType* UnsafeAnyCast(Any* operand)
|
|||||||
/// use typeid() comparison, e.g., when our types may travel across
|
/// use typeid() comparison, e.g., when our types may travel across
|
||||||
/// different shared libraries.
|
/// different shared libraries.
|
||||||
{
|
{
|
||||||
return &static_cast<Any::Holder<ValueType>*>(operand->_pHolder)->_held;
|
return &static_cast<Any::Holder<ValueType>*>(operand->content())->_held;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user