Extension methods are not distinguished from ordinary methods
Let's have an extension method:
namespace Something
{
public static class SomeExtensions
{
public static void DoSomething(this string content)
{
// Here we do something
}
}
}
Visual Studio displays: (extension) void string.DoSomething()
ReSharper displays: (method) void Something.SomeExtensions.DoSomething(this string content)
I think VS style looks much better.
I have not found any option to make ReSharper use the VS style for extension methods. :(
Is there an existing option in ReSharper I can set to see extension methods in VS style?
Please sign in to leave a comment.
You might want to try out the Enhanced Tooltip extension. It completely replaces ReSharper's tooltips with something a lot prettier. You can download it from ReSharper → Extension Manager.
See this page for more details: https://github.com/MrJul/ReSharper.EnhancedTooltip#readme
Thanks for the info.
I have tried it out and it is really prettier but unfortunately it does not really solve my issue. :(
Now it displays an extension method for an instance of List<int> type as follows:
(extension) bool System.Linq.Enumerable.Any(this [NotNull] IEnumerable<int> source)
It now says (extension) instead of (method) but I would like it to show it the following way:
(extension) bool IEnumerable<int>.Any()
Anyway, thanks again for your suggestion.
I'd suggest adding an issue to the project, describing what you'd like to see: https://github.com/MrJul/ReSharper.EnhancedTooltip/issues