You have to add a new scope too. Consider for(int i=-10;i<10;i++); for(unsigned int i=0;i<10;i++);
And I fail to see the point, really.
/ Per Hedbor ()
Previous text:
2004-05-05 11:25: Subject: precompile.pike
Ah, perhaps I'm very unclear on this point. I wish to do the following:
void f() { for(int x=0;;) ...; }
=>
void f() { int x; for(x=0;;) ...; }
ie, variables shouldn't become global, just moved within the function.
/ Marcus Agehall (Scanian)