fix array + typedef

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@5827 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
Marcelo Matus 2004-04-03 08:45:22 +00:00
commit 4e64b1e7be

View file

@ -731,10 +731,12 @@ void typemap_replace_vars(String *s, ParmList *locals, SwigType *type, String *p
/* If the original datatype was an array. We're going to go through and substitute
its array dimensions */
if (SwigType_isarray(type)) {
if (SwigType_isarray(type) || SwigType_isarray(ftype)) {
String *size;
int ndim = SwigType_array_ndim(type);
int ndim;
int i;
if (!SwigType_isarray(type)) type = ftype;
ndim = SwigType_array_ndim(type);
size = NewString("");
for (i = 0; i < ndim; i++) {
String *dim = SwigType_array_getdim(type,i);