Skip to content

Use runtime formatting for ILLink #116941

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

Merged
merged 6 commits into from
Jun 24, 2025
Merged

Use runtime formatting for ILLink #116941

merged 6 commits into from
Jun 24, 2025

Conversation

sbomer
Copy link
Member

@sbomer sbomer commented Jun 23, 2025

I was attempting to use copilot to make some ILLink changes and it was having trouble with the ILLink formatting conventions (in particular it was having trouble using tabs for indentation), so it seems like a good time to move over to the runtime formatting rules.

I deleted the ILLink .editorconfig and ran dotnet format over the various ILLink projects.

edit: I added back the .editorconfig with a few settings that weren't fixed automatically by 'dotnet format' but are
enforced by the build.

@sbomer sbomer requested review from a team and Copilot June 23, 2025 23:06
@github-actions github-actions bot added the area-Tools-ILLink .NET linker development as well as trimming analyzers label Jun 23, 2025
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR updates the ILLink codebase to use runtime formatting rules by removing the ILLink .editorconfig and running dotnet format over various projects. The key changes consist of converting tab-based indentation to space-based formatting, reformatting block constructs with consistent brace placement, and standardizing spacing across the code.

Reviewed Changes

Copilot reviewed 175 out of 1660 changed files in this pull request and generated no comments.

File Description
WarningSuppressionWriter.cs Reformatted control flow and block braces for runtime consistency
UnconditionalSuppressMessageAttributeState.cs Updated indentation and spacing in conditionals and loops
TypeReferenceWalker.cs Reformatted loops and conditionals to adhere to new formatting guidelines
(and many more) Similar formatting adjustments and whitespace cleanups across the codebase

@dotnet-policy-service dotnet-policy-service bot added the linkable-framework Issues associated with delivering a linker friendly framework label Jun 23, 2025
Copy link
Contributor

Tagging subscribers to this area: @dotnet/illink
See info in area-owners.md if you want to be subscribed.

Copy link
Member

@jtschuster jtschuster left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

Some of the .editorconfig changes weren't automatically
fixed by dotnet format. Add back those rules for now so that
this builds.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-Tools-ILLink .NET linker development as well as trimming analyzers linkable-framework Issues associated with delivering a linker friendly framework
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants