On C# extension methods’s performance

I keep using this brand new feature shipped by C# 3.0 a lot since last two years.

Some guys doubt its performance when comparing it to the regular .net static method, they don’t do any tests but just keep away from the new things…IMHO,they are little flock of sheep!

In fact,there is no need to think too much on the performance when using C#’s extension methods,which is the case of the core language developers of MS,and in my opinion,a static extension method is just a method call,the compiler will need to figure some things out at compile time but runtime it should be the same as regular method call.

Keep in mind that Microsoft is not an idiot!

2010-1-29 16-00-20

posted @ 2010-03-05 17:23  Mamboer  阅读(280)  评论(0编辑  收藏  举报