Commit bca97db6 authored by Thomas Jahns's avatar Thomas Jahns 🤸
Browse files

Add proper handling of intentionally unused functions.

* These functions are only needed when cfortran glue code passes
  strings from Fortran to C or the other way round.
parent 200c6368
......@@ -608,8 +608,7 @@ else if (e>s) { /* Watch out for neg. length string.*/
while (e>s && *--e==t){;} /* Don't follow t's past beginning. */
e[*e==t?0:1] = '\0'; /* Handle s[0]=t correctly. */
}
if (0) /* to prevent not used warnings in gcc (added by TJ) */
num_elem("", 0, '\0', 1);
(void)num_elem; /* to prevent not used warnings in gcc (added by TJ) */
return s; }
......@@ -678,10 +677,10 @@ for (num=0; ; num++) {
if (i==(unsigned)num_term) break;
else strv += elem_len-i;
}
if (0) { /* to prevent not used warnings in gcc (added by ROOT) */
c2fstrv(0, 0, 0, 0); f2cstrv(0, 0, 0, 0); kill_trailing(0, 0);
vkill_trailing(0, 0, 0, 0); num_elem(0, 0, 0, 0);
}
/* to prevent not used warnings in gcc (added by ROOT, changed by TJ
* because of unreachable warnings from clang) */
(void)c2fstrv; (void)f2cstrv; (void)kill_trailing;
(void)vkill_trailing; (void)num_elem;
return (int)num;
}
/* #endif removed 2/10/98 (CFITSIO) */
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment