simpler check/set of the 'hasconsttype' attribute
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@8487 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
b538d5e5f0
commit
42383077ea
1 changed files with 1 additions and 6 deletions
|
|
@ -374,7 +374,6 @@ static void add_symbols(Node *n) {
|
|||
Setattr(n,"hasvalue","1");
|
||||
}
|
||||
if (type) {
|
||||
SwigType *rt;
|
||||
SwigType *ty;
|
||||
SwigType *tmp = 0;
|
||||
if (decl) {
|
||||
|
|
@ -383,14 +382,10 @@ static void add_symbols(Node *n) {
|
|||
} else {
|
||||
ty = type;
|
||||
}
|
||||
rt = SwigType_typedef_resolve_all(ty);
|
||||
if (SwigType_isconst(ty)) {
|
||||
if (!SwigType_ismutable(ty)) {
|
||||
SetFlag(n,"hasconsttype");
|
||||
}
|
||||
if (!SwigType_ismutable(rt)) {
|
||||
SetFlag(n,"feature:immutable");
|
||||
}
|
||||
Delete(rt);
|
||||
if (tmp) Delete(tmp);
|
||||
}
|
||||
if (!type) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue