SWIGTYPE && input typemaps now assume object has been moved

Change these typemaps to assume that after a function call,
the parameter has been moved. The parameter's proxy class
that owns the C++ object thus has the underlying pointer set
to null so the object cannot be used again and the object is deleted.

Scrap new javarelease typemap and move contents into javabody typemap.
This commit is contained in:
William S Fulton 2022-07-10 19:08:32 +01:00
commit bf761998ed
7 changed files with 150 additions and 18 deletions

View file

@ -2025,8 +2025,6 @@ public:
typemapLookup(n, "javabody", typemap_lookup_type, WARN_JAVA_TYPEMAP_JAVABODY_UNDEF), // main body of class
NIL);
Printv(proxy_class_def, typemapLookup(n, "javarelease", typemap_lookup_type, WARN_NONE), NIL);
// C++ destructor is wrapped by the delete method
// Note that the method name is specified in a typemap attribute called methodname
String *destruct = NewString("");