Reduce versions of shared_ptr created

This commit is contained in:
Jason Turner
2015-03-23 13:44:40 -06:00
parent 9326539f3b
commit 04bceedf64
3 changed files with 4 additions and 4 deletions

View File

@@ -30,7 +30,7 @@ namespace chaiscript
Proxy_Function build_constructor_(Class (*)(Params...))
{
typedef std::shared_ptr<Class> (sig)(Params...);
return Proxy_Function(new Proxy_Function_Impl<sig>(std::function<sig>(&(constructor_<Class, Params...>))));
return Proxy_Function(static_cast<Proxy_Function_Impl_Base *>(new Proxy_Function_Impl<sig>(std::function<sig>(&(constructor_<Class, Params...>)))));
}
}
}