smart-pointer classes deriving from parent smart-pointers
white-space cleanup
This commit is contained in:
parent
e6a1a7dbd1
commit
1df744e0c3
1 changed files with 397 additions and 394 deletions
|
|
@ -534,7 +534,7 @@ void R::addSMethodInfo(String *name, String *argType, int nargs) {
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
Returns the name of the new routine.
|
Returns the name of the new routine.
|
||||||
*/
|
*/
|
||||||
String * R::createFunctionPointerHandler(SwigType *t, Node *n, int *numArgs) {
|
String * R::createFunctionPointerHandler(SwigType *t, Node *n, int *numArgs) {
|
||||||
String *funName = SwigType_manglestr(t);
|
String *funName = SwigType_manglestr(t);
|
||||||
|
|
@ -590,7 +590,7 @@ String * R::createFunctionPointerHandler(SwigType *t, Node *n, int *numArgs) {
|
||||||
|
|
||||||
emit_parameter_variables(parms, f);
|
emit_parameter_variables(parms, f);
|
||||||
emit_return_variable(n, rettype, f);
|
emit_return_variable(n, rettype, f);
|
||||||
// emit_attach_parmmaps(parms,f);
|
// emit_attach_parmmaps(parms,f);
|
||||||
|
|
||||||
/* Using weird name and struct to avoid potential conflicts. */
|
/* Using weird name and struct to avoid potential conflicts. */
|
||||||
Wrapper_add_local(f, "r_swig_cb_data", "RCallbackFunctionData *r_swig_cb_data = R_SWIG_getCallbackFunctionData()");
|
Wrapper_add_local(f, "r_swig_cb_data", "RCallbackFunctionData *r_swig_cb_data = R_SWIG_getCallbackFunctionData()");
|
||||||
|
|
@ -987,6 +987,7 @@ int R::OutputClassMemberTable(Hash *tb, File *out) {
|
||||||
/* This function checks for names ending in _set - perhaps it should */
|
/* This function checks for names ending in _set - perhaps it should */
|
||||||
/* use attributes of some other form, as it potentially clashes with */
|
/* use attributes of some other form, as it potentially clashes with */
|
||||||
/* methods ending in _set */
|
/* methods ending in _set */
|
||||||
|
|
||||||
if(n && outputNamespaceInfo) {
|
if(n && outputNamespaceInfo) {
|
||||||
Printf(s_namespace, "exportClasses(");
|
Printf(s_namespace, "exportClasses(");
|
||||||
}
|
}
|
||||||
|
|
@ -2348,13 +2349,28 @@ void R::registerClass(Node *n) {
|
||||||
Delete(base);
|
Delete(base);
|
||||||
String *smartptr = Getattr(n, "feature:smartptr");
|
String *smartptr = Getattr(n, "feature:smartptr");
|
||||||
if (smartptr) {
|
if (smartptr) {
|
||||||
|
List *l = Getattr(n, "bases");
|
||||||
SwigType *spt = Swig_cparse_type(smartptr);
|
SwigType *spt = Swig_cparse_type(smartptr);
|
||||||
String *smart = SwigType_typedef_resolve_all(spt);
|
String *smart = SwigType_typedef_resolve_all(spt);
|
||||||
String *smart_rname = SwigType_manglestr(smart);
|
String *smart_rname = SwigType_manglestr(smart);
|
||||||
Printf(s_classes, "setClass('_p%s', contains = c('%s'))\n", smart_rname, sname);
|
Printf(s_classes, "setClass('_p%s', contains = c('%s'", smart_rname, sname);
|
||||||
Delete(spt);
|
Delete(spt);
|
||||||
Delete(smart);
|
Delete(smart);
|
||||||
Delete(smart_rname);
|
Delete(smart_rname);
|
||||||
|
for(int i = 0; i < Len(l); i++) {
|
||||||
|
Node * b = Getitem(l, i);
|
||||||
|
smartptr = Getattr(b, "feature:smartptr");
|
||||||
|
if (smartptr) {
|
||||||
|
spt = Swig_cparse_type(smartptr);
|
||||||
|
smart = SwigType_typedef_resolve_all(spt);
|
||||||
|
smart_rname = SwigType_manglestr(smart);
|
||||||
|
Printf(s_classes, ", '_p%s'", smart_rname);
|
||||||
|
Delete(spt);
|
||||||
|
Delete(smart);
|
||||||
|
Delete(smart_rname);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Printf(s_classes, "))\n");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -2826,17 +2842,4 @@ String * R::processType(SwigType *t, Node *n, int *nargs) {
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*************************************************************************************/
|
/*************************************************************************************/
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue