Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to Expose Boost::shared_ptr<T> to Tcl + SWIG interface file?

Tags:

c++

swig

tcl

I want to expose the boost::shared_Ptr to Tcl layer using SWIG. but currently I don't know I could Expose this. I found out that SWIG/Lib folder contains the interface file for shared_ptr.i. But in the content I found out that I could not use it directly. It has to be included after "boost_shared_ptr.i". But there is nothing like boost_shared_ptr.i in "SWIG/Lib/tcl" folder but we have similar interface which I could include in Java.

like image 226
Apoorva sahay Avatar asked May 13 '13 07:05

Apoorva sahay


1 Answers

When I last tried there was not good support for boost/shared_ptr in all of SWIG. Python had the best coverage. I am interested to hear if this has changed.

As far as my other experience with SWIG you would also need to instantiate the template using %template for each type that you want to expose.

like image 183
Dan Macumber Avatar answered Oct 23 '22 15:10

Dan Macumber