Add additional support for boost::shared_ptr as a return type

This commit is contained in:
Jason Turner
2009-07-21 02:00:39 +00:00
parent 72b6647718
commit 00ac8113c0
3 changed files with 28 additions and 3 deletions

View File

@@ -126,7 +126,13 @@ namespace chaiscript
}
template<typename T>
boost::shared_ptr<Data> get(boost::shared_ptr<T> obj)
boost::shared_ptr<Data> get(const boost::shared_ptr<T> *obj)
{
return get(*obj);
}
template<typename T>
boost::shared_ptr<Data> get(const boost::shared_ptr<T> &obj)
{
boost::shared_ptr<Data> data(new Data(
Get_Type_Info<T>::get(),