From: <and...@hi...> - 2010-09-30 06:13:16
|
Hi I have come across a small problem that surmounts my understanding of typemaps in swig. Please consider the following minimal example: %include "typemaps.i" %include "std_string.i" %{ class TestClass { public: TestClass(); virtual ~TestClass(); bool stringTest(std::string &refString); }; %} %apply std::string &OUTPUT { std::string &refString }; class TestClass { public: TestClass(); virtual ~TestClass(); bool stringTest(std::string &refString); }; While Swig 2.0 parses this without a problem for Python, for CSharp it gives the following error: TestClass.i(11) : Warning 453: Can't apply (std::string &OUTPUT). No typemaps are defined. I have tried to find out what is missing by looking at the output of -debug-tmsearch and -debug-tmused, however, I am not enough of a Swig and CSharp expert to make sense of it. Any help is greatly appreciated. Best regards Andreas |