microsoft / microsoft/vscode-cpptools
format code issue: break in macro,
Open
Nobody has claimed this yet.
external
Feature: Code Formatting
Language Service
- Dominant language
- TypeScript
- Stars
- 6.2k
- Forks
- 1.7k
- Avg merge
- 14h 46m
- Merged PRs (30d)
- 61
Description
AlignArrayOfStructures: Left
ORIGIN:
const struct reg aa[] __CMN_RODATA = {
{ abc, 0, format, code },
{ abcd2, 0, format, code },
{ aaaa, 0, why, why },
{ whyyyy, 0, why, why },
};
add macro:
const struct reg aa[] __CMN_RODATA = {
#if A
{ abc, 0, format, code },
{ abcd2, 0, format, code },
#else
{ aaaa, 0, why, why },
{ whyyyy, 0, why, why },
#endif
};
if 0:
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the formatting behavior from the C snippets using AlignArrayOfStructures: Left, including the version with #if/#else and the if 0 case. The issue names no source files or tests, and the expected formatted output is only shown in unavailable images; done should mean agreeing on the intended formatting and adding a regression test for the macro cases.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100