Disable all Resharper warnings with a comment

后端 未结 6 705
没有蜡笔的小新
没有蜡笔的小新 2020-12-15 16:59

Is there a way to disable all Resharper warnings for a file or section of code with a single comment? I\'m trying to create some coding exercises for interviewing potential

6条回答
  •  萌比男神i
    2020-12-15 17:51

    The following worked for me.

    • Add "No Resharper" to Generated Code Regions in R# -> Options -> Code Inspection -> Generated Code
    • Use the following to suppress the warnings:

      #region No Resharper
      
      // All R# warnings are suppressed here
      
      #endregion
      

提交回复
热议问题