-
Notifications
You must be signed in to change notification settings - Fork 511
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
SA1623 - Incorrect Error on Read-Only Peoperty #2253
Comments
The error is correctly reported. Since there is no setter, the summary should start with "Gets" instead of "Gets or sets". I do however agree that the message might be seen as misleading, since the summary actually does start with "Gets". And the code fix must certainly messes up. In 1.1.0-beta001, the code fix works as expected, but the error is now reported as SA1624 which seems wrong to me since this has nothing to do with the accessibility of the property's accessors. This is the message I get with the beta version:
|
Marking this a bug, as SA1623 should be raised in this case. |
I can fix this |
Consider a read only property with read/write verbiage copypasta:
SA1623 tags this with the misleading message "text must begin with: Gets", and auto-fix changes the summary to "Gets gets or sets".
The text was updated successfully, but these errors were encountered: