You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Of particular concern is this [In, Optional] IntPtr security_attributes,.
Is this a valid violation of SA1133? How is [In] [Optional] any better than [In, Optional]? I agree for attributes on classes, methods and properties that they should be separate and on separate lines, but not neccesarily for parameters.
System.InvalidCastException occurred
Message: Exception thrown: 'System.InvalidCastException' in StyleCop.Analyzers.CodeFixes.dll
Additional information: Unable to cast object of type 'Microsoft.CodeAnalysis.CSharp.Syntax.AttributeListSyntax' to type 'Microsoft.CodeAnalysis.CSharp.Syntax.AttributeSyntax'.
Using VS2015 Update 1 (RTM), StyleCop.Analyzers 1.0.0-RC
The text was updated successfully, but these errors were encountered:
I'm fine with excluding attributes checks for parameters, since SA1134 will not be enforced for parameters as well.
This would in my opinion include generic parameters.
@vweijsters Are you able to update SA1133 and SA1134 (documentation + impl + tests) to exclude parameters and type parameters from analysis? I'd like to include this in RC 2 since it makes these new rules easier to adopt.
Sample code:
Of particular concern is this
[In, Optional] IntPtr security_attributes,
.[In] [Optional]
any better than[In, Optional]
? I agree for attributes on classes, methods and properties that they should be separate and on separate lines, but not neccesarily for parameters.Using VS2015 Update 1 (RTM), StyleCop.Analyzers 1.0.0-RC
The text was updated successfully, but these errors were encountered: