Warning suppression of annotated field

In our c# project we use zenject as our dependency injection tool. This means we end up with code like this: 

[Inject] GameOptions _gameOptions;

which resharper gives the compiler warning Field '_gameOptions' is never assigned. Lines like this are used so often in our project. I want to suppress this warning and stop highlighting it everywhere. How do I achieve this?

1 comment
Comment actions Permalink

A workaround is to add also the [UsedImplicitly] attribute but would be much better to have the same feature available in IntelliJ IDEA: https://intellij-support.jetbrains.com/hc/en-us/community/posts/206200799/comments/206913059 

 

1

Please sign in to leave a comment.