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@7586 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
1f58b1363c
commit
37a6cc366a
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;
|
String *f = 0;
|
||||||
n = Swig_methodclass(n);
|
n = Swig_methodclass(n);
|
||||||
if (Getattr(n, noattr)) {
|
if (GetFlag(n, noattr)) {
|
||||||
/* Printf(stdout,"noattr in %s\n", Getattr(n,"name")); */
|
/* Printf(stdout,"noattr in %s\n", Getattr(n,"name")); */
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
@ -541,7 +541,7 @@ Swig_cattr_search(Node *n, const String *attr, const String *noattr)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#ifdef SWIG_FAST_REC_SEARCH
|
#ifdef SWIG_FAST_REC_SEARCH
|
||||||
Setattr(n, noattr, "1");
|
SetFlag(n, noattr);
|
||||||
#endif
|
#endif
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
@ -556,7 +556,7 @@ String *
|
||||||
Swig_unref_call(Node *n) {
|
Swig_unref_call(Node *n) {
|
||||||
String* unref = 0;
|
String* unref = 0;
|
||||||
n = Swig_methodclass(n);
|
n = Swig_methodclass(n);
|
||||||
if (!Getattr(n,"feature:nounref")) {
|
if (!GetFlag(n,"feature:nounref")) {
|
||||||
unref = Getattr(n,"feature:unref");
|
unref = Getattr(n,"feature:unref");
|
||||||
unref = unref ? unref :
|
unref = unref ? unref :
|
||||||
Swig_cattr_search(n,"feature:unref","feature:nounref");
|
Swig_cattr_search(n,"feature:unref","feature:nounref");
|
||||||
|
|
@ -578,7 +578,7 @@ String *
|
||||||
Swig_ref_call(Node *n, const String* lname) {
|
Swig_ref_call(Node *n, const String* lname) {
|
||||||
String* ref = 0;
|
String* ref = 0;
|
||||||
n = Swig_methodclass(n);
|
n = Swig_methodclass(n);
|
||||||
if (!Getattr(n,"feature:noref")) {
|
if (!GetFlag(n,"feature:noref")) {
|
||||||
ref = Getattr(n,"feature:ref");
|
ref = Getattr(n,"feature:ref");
|
||||||
ref = ref ? ref :
|
ref = ref ? ref :
|
||||||
Swig_cattr_search(n,"feature:ref","feature:noref");
|
Swig_cattr_search(n,"feature:ref","feature:noref");
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue