WONKY



LOG | FILES | OVERVIEW


F diff --git a/code_generation/js/transpile_to_js.c b/code_generation/js/transpile_to_js.c --- a/code_generation/js/transpile_to_js.c +++ b/code_generation/js/transpile_to_js.c
/*print parameters*/
fprintf(out,"(");
- print_token(out,cache_type->arguments[0]->id);
- for(i=1;i<cache_type->number_of_arguments;++i)
+ if(cache_type->number_of_arguments!=0)
{
- fprintf(out,",");
- print_token(out,cache_type->arguments[i]->id);
+ print_token(out,cache_type->arguments[0]->id);
+ for(i=1;i<cache_type->number_of_arguments;++i)
+ {
+ fprintf(out,",");
+ print_token(out,cache_type->arguments[i]->id);
+ }
}
fprintf(out,")");