C# Add extension method to instance of class?

If you're talking about adding an extension method to individual instances, you can't. There's no such concept in C#. An extension method "extends" the type, not individual instances of the type.

How would you expect the compiler to know which instances had the extension applied to it at compile-time, if that knowledge is only available at execution-time?

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions