diff options
-rw-r--r-- | include/com/sun/star/uno/Any.h | 6 | ||||
-rw-r--r-- | include/com/sun/star/uno/Any.hxx | 2 |
2 files changed, 8 insertions, 0 deletions
diff --git a/include/com/sun/star/uno/Any.h b/include/com/sun/star/uno/Any.h index 8367eca7718b..7ed67e2ab4e0 100644 --- a/include/com/sun/star/uno/Any.h +++ b/include/com/sun/star/uno/Any.h @@ -267,17 +267,21 @@ public: inline bool SAL_CALL operator != ( const Any & rAny ) const; private: +#if !defined LIBO_INTERNAL_ONLY /// @cond INTERNAL // Forbid use with ambiguous type (sal_Unicode, sal_uInt16): explicit Any(sal_uInt16) SAL_DELETED_FUNCTION; /// @endcond +#endif }; +#if !defined LIBO_INTERNAL_ONLY /// @cond INTERNAL // Forbid use with ambiguous type (sal_Unicode, sal_uInt16): template<> sal_uInt16 Any::get<sal_uInt16>() const SAL_DELETED_FUNCTION; template<> bool Any::has<sal_uInt16>() const SAL_DELETED_FUNCTION; /// @endcond +#endif /** Template function to generically construct an any from a C++ value. @@ -293,7 +297,9 @@ template<> bool Any::has<sal_uInt16>() const SAL_DELETED_FUNCTION; template< class C > inline Any SAL_CALL makeAny( const C & value ); +#if !defined LIBO_INTERNAL_ONLY template<> inline Any SAL_CALL makeAny(sal_uInt16 const & value); +#endif template<> Any SAL_CALL makeAny(Any const &) SAL_DELETED_FUNCTION; diff --git a/include/com/sun/star/uno/Any.hxx b/include/com/sun/star/uno/Any.hxx index d0a45061caa1..8859fa76809b 100644 --- a/include/com/sun/star/uno/Any.hxx +++ b/include/com/sun/star/uno/Any.hxx @@ -191,8 +191,10 @@ inline Any SAL_CALL makeAny( const C & value ) return Any(value); } +#if !defined LIBO_INTERNAL_ONLY template<> Any makeAny(sal_uInt16 const & value) { return Any(&value, cppu::UnoType<cppu::UnoUnsignedShortType>::get()); } +#endif template<typename T> Any toAny(T const & value) { return makeAny(value); } |