posted this on May 23 12:29
You may read about it ReSharper Code Inspection Wiki; This suggestion is turned on by default.
You can disable this suggestion through "ReSharper | Options | Code Inspection | Inspection Severity":
As a corollary, I'd really like to enable using the "var" keyword for extracted variables by default. Resharper used to do this before my machine was reloaded -- now I can't seem to find the setting (or help on the net) to re-enable it. To be clear: this isn't to do with the warning insomuch as that, when I press ctrl-r, v, I want to get code like "var someVariableName = <extracted result>"
@Davyd, by default, ReSharper is asking if you'd like to use var or explicit type when introducing variable (see screenshot). You need to have ReSharper IntelliSense enabled for it in the options, though (ReSharper | Options | IntelliSense | General).
Thanks, I see that Resharper is remembering my last choice -- I just don't remember it even asking in the past (and, personally, I'd prefer it not to). I could be well wrong about whether or not it was asking -- but I still maintain that I'd prefer it not to ask at all as I'd always like to use var and it's just one extra confirmation I have to go through (:
Support Software by Zendesk