Does Cygwin c compiler not support c99?
or does c99 not support?:

#include <stdio.h>
#include <stdlib.h>

int main(void) {
        bool f=true;
        for(int i=0; i<10; i++) {
                if (f)
                printf("%d\n",i);
        }
        puts("Hello World!!!"); /* prints Hello World!!! */
        return EXIT_SUCCESS;
}

Here the bool declaration fails and so do the for statement. The compiler doesn't like that I use the iteration variable inside the for-loop.
What shall I do to fix it?

Cygwin 1.7.7, Eclipse Helios, Windows 7


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

Reply via email to