Hello Mike,
I am very glad you noticed both private and internal are violations of the rule number CA1811 and post it here.
Basically, when we do code analysis on our assemblies, for rule CA1811, it will analyze wethere the member is visiable outside the assembly by using a property called IsVisibleOutsideAssembly. Hence, members with private or internal keyword were considered. As we could see, private member and internal member were not considered seperately when designing the rule.
Currently, I did not see any option in Visual Studio to flag only one of them but not the other. However, we could write a custom rule for that. The follow link contains walkthroughs ans sample of custom rules, I believe it is helpful for writing custom rules:
http://www.binarycoder.net/fxcop/Best regards,
Please remember to mark the replies as answers if they help and unmark them if they provide no help.
If you have any feedback, please tell us.
Welcome to the
All-In-One Code Framework!