Fix seg fault wrapping some constant variable (%constant) types
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@11137 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
3d05f50eab
commit
1f69806cbb
3 changed files with 5 additions and 4 deletions
|
|
@ -2813,11 +2813,10 @@ int ALLEGROCL::constantWrapper(Node *n) {
|
|||
}
|
||||
|
||||
SwigType_add_qualifier(const_type, "const");
|
||||
SwigType_add_qualifier(const_type, "static");
|
||||
|
||||
String *ppcname = NewStringf("ACLppc_%s", Getattr(n, "sym:name"));
|
||||
// Printf(f_runtime, "static const %s = %s;\n", SwigType_lstr(const_type, ppcname), const_val);
|
||||
Printf(f_runtime, "%s = %s;\n", SwigType_lstr(const_type, ppcname), const_val);
|
||||
Printf(f_runtime, "static %s = %s;\n", SwigType_lstr(const_type, ppcname), const_val);
|
||||
|
||||
Setattr(n, "name", ppcname);
|
||||
SetFlag(n, "feature:immutable");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue