test virtual operators

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@9357 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
William S Fulton 2006-09-25 20:15:24 +00:00
commit eae32a8da7
3 changed files with 52 additions and 4 deletions

View file

@ -31,7 +31,16 @@ public class runme
if (op.i != 99) throw new Exception("operator-- prefix failed (op)");
if (opNew.i != 99) throw new Exception("operator-- prefix failed (opNew)");
}
// overloaded operator class
Op k = new OpDerived(3);
int check_k = k.IntCast();
Assert(check_k == 6);
}
public static void Assert(bool b) {
if (!b)
throw new Exception("Assertion failed");
}
}