aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xsystem/include/emscripten/bind.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/system/include/emscripten/bind.h b/system/include/emscripten/bind.h
index 3f857a2a..90dca77c 100755
--- a/system/include/emscripten/bind.h
+++ b/system/include/emscripten/bind.h
@@ -904,7 +904,7 @@ namespace emscripten {
template<class ConcreteWrapperType>
static std::shared_ptr<ConcreteWrapperType> cloneToSharedWrapperPtr(InterfaceType& i) {
- return std::dynamic_pointer_cast<ConcreteWrapperType>(cloneToSharedPtr<ConcreteWrapperType>(i));
+ return std::make_shared<ConcreteWrapperType>(&i);
}
void initialize(internal::EM_VAL handle) {