Modify typedef_typedef testcase to work for all languages

Add CHANGES note

Closes #112.
This commit is contained in:
William S Fulton 2014-01-13 18:42:04 +00:00
commit e531578c54
3 changed files with 11 additions and 9 deletions

View file

@ -1,5 +1,5 @@
import typedef_typedef
b = typedef_typedef.B()
if b.getValue() == 0:
if b.getValue(123) == 1234:
print "Failed !!!"

View file

@ -1,13 +1,11 @@
%module typedef_typedef
/*
// Check C::Bar::Foo resolves to A::Foo in typemap search
We want a specific behaviour on a Type
%typemap(in) SWIGTYPE, int "__wrong_in_typemap__will_not_compile__"
*/
%typemap(out) A::Foo {
$result = PyInt_FromLong($1 + 1);
%typemap(in) A::Foo {
$1 = 1234; /* A::Foo in typemap */
}
%inline %{
@ -23,8 +21,8 @@
struct B
{
C::Bar::Foo getValue() {
return 0;
C::Bar::Foo getValue(C::Bar::Foo intvalue) {
return intvalue;
}
};
%}