-
Notifications
You must be signed in to change notification settings - Fork 22
SA1112
TypeName |
ClosingParenthesisMustBeOnLineOfOpeningParenthesis |
CheckId |
SA1112 |
Category |
Readability Rules |
The closing parenthesis or bracket in a call to a C# method or indexer, or the declaration of a method or indexer, is not placed on the same line as the opening bracket when the element does not take any parameters.
A violation of this rule occurs when a method or indexer does not take any parameters andthe closing bracket of a call or declaration for the method or indexer is not placed on the same line as the opening bracket. The following example shows correct placement of the closing parenthesis:
public string GetName()
{
return this.name.Trim();
}
To fix a violation of this rule, ensure that the closing bracket is placed on the same line as the opening bracket.
[SuppressMessage("StyleCop.CSharp.ReadabilityRules", "SA1112:ClosingParenthesisMustBeOnLineOfOpeningParenthesis", Justification = "Reviewed.")]
</div>
</body>
- - SA0102 - Clean Install
- - Download
- - Documentation Rules - Layout Rules - Maintainability Rules - Naming Rules - Ordering Rules - Readability Rules - Spacing Rules - Suppressions
- - Adding a custom StyleCop settings page - Adding custom rule settings - Authoring a custom styleCop rule - Authoring rules metadata - Custom CSharp Language Service - Custom MSBuild Integration - Hosting StyleCop in a Custom Environment - Installing a Custom Rule - Integrating StyleCop Into Build Environments - Integrating StyleCop into MSBuild - Writing Custom Rules for StyleCop