From: Mark T. <mt...@gm...> - 2011-12-19 19:29:49
|
I have a class with a function that looks like this: namespace ns { class a { public: a(ns::b* bin); ns::b* b(): }; This causes problems with swig in c# when it wraps the constructor. So, in a.cs it looks like this: public a(b bin) : this(mylibPINVOKE.new_a__SWIG_2(b.getCPtr(bin)), true) { } This causes obvious problems. When the parameter to the constructor is declared, the c# compiler believes that it's referring to the wrapped implementation of a::b. Now, I could rename the function to getb() and setb(). Or, I could rename the types to differentiate with case. But, the best solution would be if swig used full scoping. How can I force swig to keep the ns:: and declare the parameter as (ns.b bin)? Thanks, Mark. |