Modify following features to work as flags, so that they can be truely set and unset:
predicate git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@7576 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
6740a841ce
commit
bc2a59ee9d
1 changed files with 2 additions and 2 deletions
|
|
@ -1099,7 +1099,7 @@ public:
|
||||||
Wrapper *f = NewWrapper();
|
Wrapper *f = NewWrapper();
|
||||||
|
|
||||||
/* Rename predicate methods */
|
/* Rename predicate methods */
|
||||||
if (Getattr(n, "feature:predicate")) {
|
if (GetFlag(n, "feature:predicate")) {
|
||||||
Append(symname, "?");
|
Append(symname, "?");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1224,7 +1224,7 @@ public:
|
||||||
/* Return value if necessary */
|
/* Return value if necessary */
|
||||||
if (SwigType_type(t) != T_VOID && current != CONSTRUCTOR_ALLOCATE && current != CONSTRUCTOR_INITIALIZE) {
|
if (SwigType_type(t) != T_VOID && current != CONSTRUCTOR_ALLOCATE && current != CONSTRUCTOR_INITIALIZE) {
|
||||||
need_result = 1;
|
need_result = 1;
|
||||||
if (Getattr(n, "feature:predicate")) {
|
if (GetFlag(n, "feature:predicate")) {
|
||||||
Printv(f->code, tab4, "vresult = (result ? Qtrue : Qfalse);\n", NIL);
|
Printv(f->code, tab4, "vresult = (result ? Qtrue : Qfalse);\n", NIL);
|
||||||
} else {
|
} else {
|
||||||
tm = Swig_typemap_lookup_new("out",n,"result",0);
|
tm = Swig_typemap_lookup_new("out",n,"result",0);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue