fix unused parms in last commit for C code

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10558 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
William S Fulton 2008-06-22 21:30:20 +00:00
commit f85ef02890

View file

@ -1802,11 +1802,11 @@ void SwigType_inherit_equiv(File *out) {
char *newmemoryused = Strstr(convcode, "newmemory"); /* see if newmemory parameter is used in order to avoid unused paramater warnings */
String *fn = Copy(convcode);
Replaceall(fn, "$from", "x");
Printf(out, "static void *%s(void *x, int *%s) {", convname, newmemoryused ? "newmemory" : "");
Printf(out, "static void *%s(void *x, int *%s) {", convname, newmemoryused ? "newmemory" : "SWIGUNUSEDPARM(newmemory)");
Printf(out, "%s", fn);
} else {
String *cast = Getattr(subhash, "cast");
Printf(out, "static void *%s(void *x, int *) {", convname);
Printf(out, "static void *%s(void *x, int *SWIGUNUSEDPARM(newmemory)) {", convname);
Printf(out, "\n return (void *)((%s) ", lkey);
if (cast)
Printf(out, "%s", cast);