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

DSLX formatter should reflow multi-line comments as a whole #1687

Open
mikex-oss opened this issue Nov 1, 2024 · 0 comments
Open

DSLX formatter should reflow multi-line comments as a whole #1687

mikex-oss opened this issue Nov 1, 2024 · 0 comments
Labels
dslx:fmt DSLX auto-formatter enhancement New feature or request

Comments

@mikex-oss
Copy link
Collaborator

What's hard to do? (limit 100 words)

When updating a multi-line comment, the formatter only fixes the current line length, moving extra words to a new line, but leaving the rest of the multi-line comment as is. This leaves a bunch of empty white space.

For example:

// XLS (Accelerated HW Synthesis) aims to be the Software Development Kit (SDK) for the End of
// Moore's Law (EoML) era. In this "age of specialization", software and hardware engineers must do
// more co-design across their domain boundaries -- collaborate on shared artifacts, understand each
// other's cost models, and share tooling/methodology. XLS attempts to leverage automation, software
// engineers, and machine cycles to accelerate this overall process.

Update the end of line 2 to "software and hardware engineers and executives must do". Autoformatter spits out:

// XLS (Accelerated HW Synthesis) aims to be the Software Development Kit (SDK) for the End of
// Moore's Law (EoML) era. In this "age of specialization", software and hardware engineers and
// executives must do
// more co-design across their domain boundaries -- collaborate on shared artifacts, understand each
// other's cost models, and share tooling/methodology. XLS attempts to leverage automation, software
// engineers, and machine cycles to accelerate this overall process.

Current best alternative workaround (limit 100 words)

Keep adjusting and reformatting line by line.

Your view of the "best case XLS enhancement" (limit 100 words)

Reflow the entire comment.

@mikex-oss mikex-oss added enhancement New feature or request dslx:fmt DSLX auto-formatter labels Nov 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dslx:fmt DSLX auto-formatter enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant