Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

For loops with variable declaration messes up token input/output positions #3

Open
mstorsjo opened this issue Jan 12, 2013 · 0 comments

Comments

@mstorsjo
Copy link
Contributor

This input gets converted incorrectly
int main () { for( int i = 0; i < 9; i++ ); return 0; }
into this:
int main () { { int i = 0; for( ; i < 9; i++ ); }return0; }

The token input/output positions need to be updated correctly.. somewhere.., so we produce enough whitespace between "return0;". I added a test case for it in a branch in my repo as well: mstorsjo@for-loop-test

This exact piece of code is used in x264's configure script for testing for the C99 features.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant