Modify following features to work as flags, so that they can be truely set and unset: nounref, noref, noattr
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@7586 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
a333a56da0
commit
dda5e32a18
1 changed files with 4 additions and 4 deletions
|
|
@ -517,7 +517,7 @@ Swig_cattr_search(Node *n, const String *attr, const String *noattr)
|
|||
{
|
||||
String *f = 0;
|
||||
n = Swig_methodclass(n);
|
||||
if (Getattr(n, noattr)) {
|
||||
if (GetFlag(n, noattr)) {
|
||||
/* Printf(stdout,"noattr in %s\n", Getattr(n,"name")); */
|
||||
return 0;
|
||||
}
|
||||
|
|
@ -541,7 +541,7 @@ Swig_cattr_search(Node *n, const String *attr, const String *noattr)
|
|||
}
|
||||
}
|
||||
#ifdef SWIG_FAST_REC_SEARCH
|
||||
Setattr(n, noattr, "1");
|
||||
SetFlag(n, noattr);
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
|
@ -556,7 +556,7 @@ String *
|
|||
Swig_unref_call(Node *n) {
|
||||
String* unref = 0;
|
||||
n = Swig_methodclass(n);
|
||||
if (!Getattr(n,"feature:nounref")) {
|
||||
if (!GetFlag(n,"feature:nounref")) {
|
||||
unref = Getattr(n,"feature:unref");
|
||||
unref = unref ? unref :
|
||||
Swig_cattr_search(n,"feature:unref","feature:nounref");
|
||||
|
|
@ -578,7 +578,7 @@ String *
|
|||
Swig_ref_call(Node *n, const String* lname) {
|
||||
String* ref = 0;
|
||||
n = Swig_methodclass(n);
|
||||
if (!Getattr(n,"feature:noref")) {
|
||||
if (!GetFlag(n,"feature:noref")) {
|
||||
ref = Getattr(n,"feature:ref");
|
||||
ref = ref ? ref :
|
||||
Swig_cattr_search(n,"feature:ref","feature:noref");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue