1 comment
Comment actions Permalink

Hello Greg,

I think the question whether such a constructor is redundant or not is somewhat
obscure from the viewpoint
of C# semantics. On one side, the constructor is not necessarily for successful
compilation of the program. On
other side, it changes the runtime behavior of code, so it should be really
better not to mark it as redundant.
Could you please file a request for it to the tracker? Thanks.

Dmitry Shaporenkov
JetBrains, Inc
"Develop with pleasure!"

When implementing the Singleton pattern as per this discussion:


R# marks the empty static constructor as redundant, when in fact it is
necessary. Any chance this could be worked around somehow?



Please sign in to leave a comment.