Closed csrabak closed 8 months ago
Indeed. The preparser unduly replaces defines in character and string literals. Hence, the following simple code is importable but will also produce a wrong result:
#include <stdio.h>
#define funny nasty
int main(int argc, char* argv[])
{
printf("This will be funny.\n");
return 0;
}
Fix for this issue is prepared to be delivered with version 3.32-17. @csrabak A temporary workaround may be to enable C-specific import option "Convert #defines to constants":
Thanks for quick fix and workaroud meanwhile!
This code when importing is done in Structorizer:
Fails with an interruption in the importing process with the following diagonostic:
The defined constant c in the fourth line of code was expanded in the char 'c' constant of the
switch
.