summaryrefslogtreecommitdiff
path: root/stoc/source/corereflection/base.hxx
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2016-06-21 14:05:17 +0200
committerStephan Bergmann <sbergman@redhat.com>2016-06-21 14:05:17 +0200
commit9cef658364e4d8441f490e4fe89c3bfa14cd24b3 (patch)
treed3759856838bb9fc6af85694bbe4c594f728e8f7 /stoc/source/corereflection/base.hxx
parent7669bf3884ac053baca04e09d7c9994870983a4a (diff)
Clean up uses of Any::getValue() in stoc
Change-Id: I455b708bfcc9d5aa71bb0ffc21efec205302169e
Diffstat (limited to 'stoc/source/corereflection/base.hxx')
-rw-r--r--stoc/source/corereflection/base.hxx7
1 files changed, 5 insertions, 2 deletions
diff --git a/stoc/source/corereflection/base.hxx b/stoc/source/corereflection/base.hxx
index f28a600ac75a..cdfcb3f2f7b1 100644
--- a/stoc/source/corereflection/base.hxx
+++ b/stoc/source/corereflection/base.hxx
@@ -21,6 +21,9 @@
#ifndef INCLUDED_STOC_SOURCE_COREREFLECTION_BASE_HXX
#define INCLUDED_STOC_SOURCE_COREREFLECTION_BASE_HXX
+#include <sal/config.h>
+
+#include <o3tl/any.hxx>
#include <osl/diagnose.h>
#include <osl/mutex.hxx>
#include <uno/mapping.hxx>
@@ -366,9 +369,9 @@ inline bool extract(
reinterpret_cast< uno_AcquireFunc >(css::uno::cpp_acquire),
reinterpret_cast< uno_ReleaseFunc >(css::uno::cpp_release) );
}
- else if (rObj.getValueTypeClass() == css::uno::TypeClass_TYPE)
+ else if (auto t = o3tl::tryAccess<css::uno::Type>(rObj))
{
- rDest = pRefl->forType( static_cast< const css::uno::Type * >( rObj.getValue() )->getTypeLibType() );
+ rDest = pRefl->forType( t->getTypeLibType() );
return rDest.is();
}
}