Revert support for %extend and memberin typemaps added in swig-1.3.39. The memberin typemaps are ignored again for member variables within a %extend block. Documentation inconsistency reported by Torsten Landschoff.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@11762 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
b9817010fb
commit
2bd190dbf1
9 changed files with 85 additions and 38 deletions
|
|
@ -1207,7 +1207,7 @@ int Swig_DestructorToFunction(Node *n, String *classname, int cplus, int flags)
|
|||
* This function creates a C wrapper for setting a structure member.
|
||||
* ----------------------------------------------------------------------------- */
|
||||
|
||||
int Swig_MembersetToFunction(Node *n, String *classname, int flags, String **call) {
|
||||
int Swig_MembersetToFunction(Node *n, String *classname, int flags) {
|
||||
String *name;
|
||||
ParmList *parms;
|
||||
Parm *p;
|
||||
|
|
@ -1255,21 +1255,23 @@ int Swig_MembersetToFunction(Node *n, String *classname, int flags, String **cal
|
|||
Delete(p);
|
||||
|
||||
if (flags & CWRAP_EXTEND) {
|
||||
String *call;
|
||||
String *cres;
|
||||
String *code = Getattr(n, "code");
|
||||
if (code) {
|
||||
/* I don't think this ever gets run - WSF */
|
||||
Swig_add_extension_code(n, mangled, parms, void_type, code, cparse_cplusplus, "self");
|
||||
}
|
||||
*call = Swig_cfunction_call(mangled, parms);
|
||||
cres = NewStringf("%s;", *call);
|
||||
call = Swig_cfunction_call(mangled, parms);
|
||||
cres = NewStringf("%s;", call);
|
||||
Setattr(n, "wrap:action", cres);
|
||||
Delete(call);
|
||||
Delete(cres);
|
||||
} else {
|
||||
String *cres;
|
||||
*call = Swig_cmemberset_call(name, type, self, varcref);
|
||||
cres = NewStringf("%s;", *call);
|
||||
String *call = Swig_cmemberset_call(name, type, self, varcref);
|
||||
String *cres = NewStringf("%s;", call);
|
||||
Setattr(n, "wrap:action", cres);
|
||||
Delete(call);
|
||||
Delete(cres);
|
||||
}
|
||||
Setattr(n, "type", void_type);
|
||||
|
|
|
|||
|
|
@ -348,7 +348,7 @@ extern int ParmList_is_compactdefargs(ParmList *p);
|
|||
extern int Swig_MethodToFunction(Node *n, String *classname, int flags, SwigType *director_type, int is_director);
|
||||
extern int Swig_ConstructorToFunction(Node *n, String *classname, String *none_comparison, String *director_ctor, int cplus, int flags);
|
||||
extern int Swig_DestructorToFunction(Node *n, String *classname, int cplus, int flags);
|
||||
extern int Swig_MembersetToFunction(Node *n, String *classname, int flags, String **call);
|
||||
extern int Swig_MembersetToFunction(Node *n, String *classname, int flags);
|
||||
extern int Swig_MembergetToFunction(Node *n, String *classname, int flags);
|
||||
extern int Swig_VargetToFunction(Node *n, int flags);
|
||||
extern int Swig_VarsetToFunction(Node *n, int flags);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue