What does "Inconsistent modifiers style" mean in Resharper?

Asked

Viewed 138 times

2

Resharper is suggesting the following change in code:

SS

Obs:

  1. To classe Pagamento has public methods.
  2. Why the suggestion internaland not public?

1 answer

3


Your intention is for the class to be public? Then there is a mistake there, you need to say that it is public explicitly.

Should the class be internal? That is, it should be accessible only within its own Assembly? Ok, so that’s right, but Resharper is set to make this explicit. C# compiler adopts accessibility default of the class as internal itself, and it works, but Resharper thinks you should make it explicit to prevent this accessibility from being adopted by accident. Just what seems to be happening in this case.

Or turn this off in Resharper settings, or make it explicit that she’s an intern.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.