Geeks With Blogs

News FAQ on the correct forum to post at: http://forums.asp.net/p/1337412/2699239.aspx#2699239

Tatworth
Yesterday I installed the new version of Resharper (if you have not tried out ReSharper yet I urge you to get a copy, install it and try it out.)

The first new feature I wish to deal with is an assist with globalisation.  Instead of having to wait for FXCOP to check the code, ReSharper will prompt you where changes are required.

For example the line:
if (string.Compare(propertyName.ToString(), "not", true) == 0)
should be
if (System.String.Compare(propertyName.ToString(), "not", StringComparison.OrdinalIgnoreCase) == 0)

Or
sortedvalues.Add(((char)i).ToString());
should be:
sortedvalues.Add(((char)i).ToString(CultureInfo.InvariantCulture));

Agains ReSharper helps you write better code more quickly.

Posted on Friday, December 30, 2011 7:32 PM | Back to top


Comments on this post: Resharper 6.1 - new nice features - 1

# re: Resharper 6.1 - new nice features - 1
Requesting Gravatar...
Hello Tatworth,

I also like the new resharper features, however the overload used is not culture specific at all, R# is suggesting to use another overload which would be called by .NET internally for this specific overload with the boolean parameter.

I find the culture suggestion for this specific overload to be confusing and perhaps even unnecessary?

~Just my 2c
Left by Jos Krause on Sep 05, 2012 9:58 AM

Your comment:
 (will show your gravatar)


Copyright © TATWORTH | Powered by: GeeksWithBlogs.net