diff --git a/compiler/libpc300/sc1.c b/compiler/libpc300/sc1.c index dbd577ba..89c12f94 100755 --- a/compiler/libpc300/sc1.c +++ b/compiler/libpc300/sc1.c @@ -5232,9 +5232,10 @@ static symbol *fetchlab(char *name) static int is_variadic(symbol *sym) { + arginfo *arg; + assert(sym->ident==iFUNCTN); - arginfo *arg = sym->dim.arglist; - while (arg->ident) { + for (arg = sym->dim.arglist; arg->ident; arg++) { if (arg->ident == iVARARGS) return TRUE; arg++;