Code Completion null correcting to NullReferenceException
I know there has been a lot of issues with code completion, but I couldn't find an example of this specific problem. Whenever I'm looking for "null" to enter into my code it always provides me with "NullReferenceException" until I type in "null". Given that this is probably one of the words I type most often in my code, this is incredibly frustrating and always need to catch myself before pressing enter. I am open to the idea that I may have taught intellisense to do this and everytime I mistakenly insert NullReferenceException I'm just reinforcing it. (I'm not familiar with how exactly code completion works, but some kind of machine learning seems within the realm of possibility).
Either way I would like to stop it doing this? Any suggestions?

Please sign in to leave a comment.
Hi Alex,
Could you please clarify your Rider version?
Since 2018.2, we introduced a code suggestion scoring in Rider. So, ReSharper statistics-based scoring algorithm to provide code completion is used. One of the key aspects is that Rider now keeps track of how many times a given code suggestion is used. The more a suggestion is used, the more likely it will show up in code completion. Probably, clearing Rider caches and filling the statistic from scratch could help you. To clear Rider caches, one needs to call the action "Invalidate Caches/Restart."
If this does not help, please open a new support request or file an issue on our bug tracker https://youtrack.jetbrains.com/ and attach the following info:
- Navigate to `Help | Diagnostic tools | Logs settings` and enable Trace scenario for "Completion";
- Reproduce the issue, collect the full log bundle via `Help | Compress logs`, disable Trace scenarios;
- Attach the resulting log bundle to a created ticket for further investigation.
Kind regards,
Sofia.
Hi Sofia,
I'm now on 2020.1 and this fix worked. Thanks for this.
Alex