Multiple inheritance workarounds for C#
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@5503 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
09d0af6fea
commit
05b947216a
2 changed files with 6 additions and 2 deletions
|
|
@ -53,18 +53,19 @@ class AA {
|
|||
};
|
||||
|
||||
/* Multiple inheritance between two abstract classes */
|
||||
#ifndef SWIGJAVA
|
||||
class E : public C, public AA {
|
||||
public:
|
||||
virtual void something() { };
|
||||
};
|
||||
|
||||
/* Fill in method from AA. This class should be constructable */
|
||||
#ifdef SWIGCSHARP
|
||||
%ignore F::method2(); // Work around for lack of multiple inheritance support - base AA is ignored.
|
||||
#endif
|
||||
class F : public E {
|
||||
public:
|
||||
virtual void method2() { }
|
||||
};
|
||||
#endif
|
||||
|
||||
%}
|
||||
|
||||
|
|
|
|||
|
|
@ -51,6 +51,9 @@ namespace oss
|
|||
%inline %{
|
||||
namespace oss
|
||||
{
|
||||
#ifdef SWIGCSHARP
|
||||
%ignore HModule<B>::get(); // Work around for lack of multiple inheritance support - base ModuleBase is ignored.
|
||||
#endif
|
||||
struct test : HModule<B>
|
||||
{
|
||||
virtual int get() {return 0;} // declaration here breaks swig
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue