Get List of Zero Reference Codes in Visual Studio

前端 未结 4 2010
忘掉有多难
忘掉有多难 2020-11-27 10:08

In visual studio 2013 the number of references of a special Code(method, property, field,...) is shown by Code Lens. I want to get unused (zero refe

4条回答
  •  谎友^
    谎友^ (楼主)
    2020-11-27 10:27

    https://scottlilly.com/c-code-quality-improvement/remove-unused-classes-properties-and-functions/

    "Unfortunately, [in Visual Studio Analysis] you can only detect unused private members. This is because the code analyzer assumes public members might be used by other programs. This could be true if you’re publishing them as an API through a web service or releasing your code as a library. ... ReSharper has similar code analysis functions – with the advantage of checking for unused public members."

提交回复
热议问题