From 5415b1da208b4099bc58e9b9fafe755233ad61f8 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 26 Oct 2006 18:42:40 +0000 Subject: [PATCH] Fix %ignore director constructors git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@9484 626c5289-ae23-0410-ae9c-e8d60b6d4f22 --- SWIG/Source/Modules/csharp.cxx | 4 ---- SWIG/Source/Modules/java.cxx | 4 ---- SWIG/Source/Modules/lang.cxx | 2 +- 3 files changed, 1 insertion(+), 9 deletions(-) diff --git a/SWIG/Source/Modules/csharp.cxx b/SWIG/Source/Modules/csharp.cxx index 485e467ce..981275448 100644 --- a/SWIG/Source/Modules/csharp.cxx +++ b/SWIG/Source/Modules/csharp.cxx @@ -3507,13 +3507,11 @@ class CSHARP : public Language { String *target = Swig_method_decl(decl, classname, parms, 0, 0); String *call = Swig_csuperclass_call(0, basetype, superparms); String *classtype = SwigType_namestr(Getattr(n, "name")); - String *dirclass_type = SwigType_namestr(Getattr(n, "sym:name")); Printf(f_directors, "%s::%s : %s, %s {\n", classname, target, call, Getattr(parent, "director:ctor")); Printf(f_directors, " swig_init_callbacks();\n"); Printf(f_directors, "}\n\n"); - Delete(dirclass_type); Delete(classtype); Delete(target); Delete(call); @@ -3540,7 +3538,6 @@ class CSHARP : public Language { int classDirectorDefaultConstructor(Node *n) { String *classname = Swig_class_name(n); String *classtype = SwigType_namestr(Getattr(n, "name")); - String *dirclass_type = SwigType_namestr(Getattr(n, "sym:name")); Wrapper *w = NewWrapper(); Printf(w->def, "SwigDirector_%s::SwigDirector_%s() : %s {", @@ -3550,7 +3547,6 @@ class CSHARP : public Language { Printf(f_directors_h, " SwigDirector_%s();\n", classname); DelWrapper(w); - Delete(dirclass_type); Delete(classtype); Delete(classname); return Language::classDirectorDefaultConstructor(n); diff --git a/SWIG/Source/Modules/java.cxx b/SWIG/Source/Modules/java.cxx index 725d737c0..acd5dd249 100644 --- a/SWIG/Source/Modules/java.cxx +++ b/SWIG/Source/Modules/java.cxx @@ -3622,12 +3622,10 @@ class JAVA : public Language { String *target = Swig_method_decl(decl, classname, parms, 0, 0); String *call = Swig_csuperclass_call(0, basetype, superparms); String *classtype = SwigType_namestr(Getattr(n, "name")); - String *dirclass_type = SwigType_namestr(Getattr(n, "sym:name")); Printf(f_directors, "%s::%s : %s, %s {\n", classname, target, call, Getattr(parent, "director:ctor")); Printf(f_directors, "}\n\n"); - Delete(dirclass_type); Delete(classtype); Delete(target); Delete(call); @@ -3655,7 +3653,6 @@ class JAVA : public Language { int classDirectorDefaultConstructor(Node *n) { String *classname = Swig_class_name(n); String *classtype = SwigType_namestr(Getattr(n, "name")); - String *dirclass_type = SwigType_namestr(Getattr(n, "sym:name")); Wrapper *w = NewWrapper(); Printf(w->def, "SwigDirector_%s::SwigDirector_%s(JNIEnv *jenv) : %s {", @@ -3665,7 +3662,6 @@ class JAVA : public Language { Printf(f_directors_h, " SwigDirector_%s(JNIEnv *jenv);\n", classname); DelWrapper(w); - Delete(dirclass_type); Delete(classtype); Delete(classname); directorPrefixArgs(n); diff --git a/SWIG/Source/Modules/lang.cxx b/SWIG/Source/Modules/lang.cxx index 3a6316314..c780c873e 100644 --- a/SWIG/Source/Modules/lang.cxx +++ b/SWIG/Source/Modules/lang.cxx @@ -1894,7 +1894,7 @@ int Language::classDirectorConstructors(Node *n) { /* emit constructors */ for (ni = Getattr(n, "firstChild"); ni; ni = nextSibling(ni)) { nodeType = Getattr(ni, "nodeType"); - if (Cmp(nodeType, "constructor") == 0 && !GetFlag(ni, "feature:ignore")) { + if (Cmp(nodeType, "constructor") == 0) { Parm *parms = Getattr(ni,"parms"); if (is_public(ni)) { /* emit public constructor */