sdcc: can't make the --std-c99 option to work
Posted: Fri Oct 05, 2018 11:39 am
I would like to declare variables in the middle of a function, not just at the top, but sdcc does not allow me to.
I tried to pass the switch -Cs--std-c99 to enable C99 standard, but it doesn't seem to work:
what I am missing?
I tried to pass the switch -Cs--std-c99 to enable C99 standard, but it doesn't seem to work:
Code: Select all
int x()
{
x();
int z=3;
}
zsdcc --constseg rodata_compiler -mz80 --no-optsdcc-in-asm --c1mode --emit-externs --no-c-code-in-asm --verbose --std-c99 --no-peep --peep-file "C:\Programmi\z88dk\lib\config\..\..\/libsrc/_DEVELOPMENT/sdcc_peeph.3" < "C:\Users\Nino\AppData\Local\Temp\zcc4A672.i" -o "C:\Users\Nino\AppData\Local\Temp\zcc4A672.opt"
sdcc: Generating code...
lib500.c:4: syntax error: token -> 'int' ; column 5