Fix typemap delete regression introduced in rev 11838

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12008 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
William S Fulton 2010-05-03 22:58:27 +00:00
commit 03bd7005bb
4 changed files with 26 additions and 4 deletions

View file

@ -387,6 +387,7 @@ CPP_TEST_CASES += \
typedef_scope \
typedef_sizet \
typedef_struct \
typemap_delete \
typemap_global_scope \
typemap_namespace \
typemap_ns_using \

View file

@ -0,0 +1,5 @@
import typemap_delete
r = typemap_delete.Rect(123)
if r.val != 123:
raise RuntimeError

View file

@ -0,0 +1,16 @@
%module typemap_delete
%typemap(in) Rect* (Rect temp) {
$1 = 0;
will_not_compile
}
%typemap(in) Rect*;
%inline %{
struct Rect
{
int val;
Rect(int v) : val(v) {}
};
%}