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

[StyleCleanUp] Add missing accessibility modifiers on members (IDE0040) #10021

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

h3xds1nz
Copy link
Contributor

@h3xds1nz h3xds1nz commented Oct 30, 2024

Fixes #10284
Fixes #10288

Description

Adds missing accessibility modifiers throughout the codebase. All of the edits were done automatically.

Customer Impact

Cleaner codebase.

Regression

No.

Testing

Local build.

Risk

Minimal.

Microsoft Reviewers: Open in CodeFlow

@h3xds1nz h3xds1nz requested review from a team as code owners October 30, 2024 15:04
@dotnet-policy-service dotnet-policy-service bot added PR metadata: Label to tag PRs, to facilitate with triage Community Contribution A label for all community Contributions labels Oct 30, 2024
}
private static WriterState state = new Start();

private Start() { }
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this really the standard to put empty constructor/methods in a single line ? From a quick look, this doesn't seem to be the case in WPF, WinForms or Runtime and I couldn't find any documentation about it.

It's probably best to revert these changes to separate them and be able to discuss it separately.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good catch, that wasn't intentional but it's a setting. Like I've said, I just ran it.

I'll manually revert this later.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

With that being said though:

There's quite a lot! But I'll revert it, not a scope of the PR.

@dipeshmsft
Copy link
Member

@h3xds1nz
all the changes were done automatically as in ?

@h3xds1nz
Copy link
Contributor Author

h3xds1nz commented Nov 10, 2024

@h3xds1nz all the changes were done automatically as in ?

@dipeshmsft Means I didn't do these by hand, just applied fix per-project.

@h3xds1nz h3xds1nz force-pushed the xaml-accessibility-modifiers branch from 16c26f2 to 9e27641 Compare January 9, 2025 03:41
@h3xds1nz h3xds1nz changed the title [Cleanup] Add missing accessibility modifiers in System.Xaml (IDE0040) [Cleanup] Add missing accessibility modifiers on members (IDE0040) Jan 9, 2025
@h3xds1nz h3xds1nz force-pushed the xaml-accessibility-modifiers branch from 9e27641 to 28e59e7 Compare January 9, 2025 10:57
@h3xds1nz
Copy link
Contributor Author

h3xds1nz commented Jan 9, 2025

@harshit7962 Should be all done; I've built it on top of this one, felt easier.

And yeah, solving IDE0040 resolved SA1400 occurrences as well, so I've removed both from .editorconfig.

@h3xds1nz h3xds1nz changed the title [Cleanup] Add missing accessibility modifiers on members (IDE0040) [StyleCleanUp] Add missing accessibility modifiers on members (IDE0040) Jan 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Community Contribution A label for all community Contributions PR metadata: Label to tag PRs, to facilitate with triage Queue for test pass Status:Proposed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SA1400: Element should declare an access modifier IDE0040: Add accessibility modifiers
5 participants