-
Notifications
You must be signed in to change notification settings - Fork 173
Closed
Description
diff --git a/source/src/BNFC/Backend/C/CFtoFlexC.hs b/source/src/BNFC/Backend/C/CFtoFlexC.hs
index 5f56765..85f7cc1 100644
--- a/source/src/BNFC/Backend/C/CFtoFlexC.hs
+++ b/source/src/BNFC/Backend/C/CFtoFlexC.hs
@@ -98,7 +98,8 @@ prelude name = unlines
"{",
" loc->first_line = loc->last_line;",
" loc->first_column = loc->last_column;",
- " for (int i = 0; text[i] != '\\0'; ++i) {",
+ " int i;",
+ " for (i = 0; text[i] != '\\0'; ++i) {",
" if (text[i] == '\\n') {",
" ++loc->last_line;",
" loc->last_column = 0; ",
This helped to make
without errors.