Fix for constants attempting to generate setters with %feature(immutable,"0")

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@7659 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
William S Fulton 2005-10-15 01:14:21 +00:00
commit 09444a7208
3 changed files with 3 additions and 0 deletions

View file

@ -1128,6 +1128,7 @@ class CSHARP : public Language {
Printf(constants_code, "%s.%s();\n", imclass_name, Swig_name_get(symname));
// Each constant and enum value is wrapped with a separate PInvoke function call
SetFlag(n,"feature:immutable");
enum_constant_flag = true;
variableWrapper(n);
enum_constant_flag = false;

View file

@ -1325,6 +1325,7 @@ class JAVA : public Language {
Printf(constants_code, "%s.%s();\n", imclass_name, Swig_name_get(symname));
// Each constant and enum value is wrapped with a separate JNI function call
SetFlag(n,"feature:immutable");
enum_constant_flag = true;
variableWrapper(n);
enum_constant_flag = false;

View file

@ -628,6 +628,7 @@ public:
Setattr(n,"name",var_name);
Setattr(n,"sym:name",iname);
Setattr(n,"type", type);
SetFlag(n,"feature:immutable");
variableWrapper(n);
Delete(n);
}