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

Preprocessor block folding #1584

Closed
kevinmoran opened this issue Feb 18, 2018 · 2 comments
Closed

Preprocessor block folding #1584

kevinmoran opened this issue Feb 18, 2018 · 2 comments

Comments

@kevinmoran
Copy link

void foo()
{
    int x = 10;
#if 0
    int y = x;
#else
    int y = x + 1;
#endif
    // etc.
}

If I try to collapse foo() in VSCode it will only fold as far as #if 0 due to the tab alignment. Aligning preprocessor statements to the left regardless of the alignment of the block itself is an extremely common style. It would be lovely if code folding understood that they are inside a function and should be folded with it.

@sean-mcmanus
Copy link
Collaborator

I don't believe we can implement this yet -- see microsoft/vscode#3422 .

@sean-mcmanus
Copy link
Collaborator

We're tracking this with #407 .

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

No branches or pull requests

3 participants