/tags/rel-1-3-26/SWIG/Examples/test-suite/inherit.i

# · Swig · 19 lines · 14 code · 5 blank · 0 comment · 0 complexity · 3230acb96d0c72b664e2f4a6c6ba9f5c MD5 · raw file

  1. // Test that was failing for Perl - the non-member Foo was being called when the member version was intended
  2. %module inherit
  3. %inline %{
  4. const char* Foo(void) {
  5. return "Non-member Foo";
  6. }
  7. class CBase {
  8. public:
  9. const char* Foo(void) {
  10. return "CBase::Foo";
  11. }
  12. };
  13. class CDerived : public CBase {};
  14. %}