Resharper: How to hide suppressed warnings in Inspection Results?

谁说我不能喝 提交于 2019-12-08 03:49:33

问题


I suppressed a Resharper warning in a VB.NET class file (*.vb). As expected, the warning is not highlighted at the border of the text editor.

If I show all Resharper warnings for my project I would expect that the suppressed warning is neither shown in the Inspection Results view. However, it is shown, see screen shot.

How to I hide warnings in the InspectionResults that are suppressed in the code with an annotation?

I am using Resharper 8.2.3

(If you have issues with public properties in respect to xaml bindings also see this related question: Resharper says OnPropertyChange set member can be private while not true)


回答1:


This appears to be a bug in ReSharper. It works as expected (that is, the suppressed warning does not appear in the find results) if you use the disable and restore style comments, rather than the disable once comments. I.e.:

' ReSharper disable MemberCanBePrivate.Global
Public Property Foo As String
' ReSharper restore MemberCanBePrivate.Global

I've raised an issue that you can track and vote on: https://youtrack.jetbrains.com/issue/RSRP-444615



来源:https://stackoverflow.com/questions/31291549/resharper-how-to-hide-suppressed-warnings-in-inspection-results

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!