string reference test fixes
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@7106 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
4c407f6847
commit
4cff098887
1 changed files with 9 additions and 4 deletions
|
|
@ -16,8 +16,13 @@ public class director_string_runme {
|
|||
|
||||
B b = new B("hello");
|
||||
|
||||
b.get(0);
|
||||
b.get_first();
|
||||
String s;
|
||||
|
||||
s = b.call_get_first();
|
||||
if (!s.equals("B.get_first")) throw new RuntimeException("call_get_first() failed");
|
||||
|
||||
s = b.call_get(0);
|
||||
if (!s.equals("B.get: hello")) throw new RuntimeException("get(0) failed");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -26,11 +31,11 @@ class B extends A {
|
|||
super(first);
|
||||
}
|
||||
public String get_first() {
|
||||
return get(0);
|
||||
return "B.get_first";
|
||||
}
|
||||
|
||||
public String get(int n) {
|
||||
return super.get(n);
|
||||
return "B.get: " + super.get(n);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue