Open
Description
The following sequence is needed to reproduce the bug:
goto-cc original.c -o original.goto
goto-instrument --unwind 4 original.goto original-unwound.goto
goto-instrument --dump-c original-unwound.goto
In the case of unwinding, dump-c produces multiple copies of variable definitions and does not correctly translate the later loop bodies (omitting function calls). If --inline is used instead of --unwind the result doesn't appear to be valid C.
I have full example code if anyone wants a go at fixing this but because github sucks I can't actually attach it to this bug report.