So .NET 4.5 introduces the CallerMemberNameAttribute
, which seems like a godsend to anyone working with WPF and implementing INotifyPropertyChanged
- my question is this: Is the attribute intrinsically tied/supported by the 4.5 5.0 compiler, or is it more of a syntactical sugar helper by the environment, much like one could fake out Visual Studio by declaring an ExtensionAttribute
of your own, magically turning on LINQ syntax?
Edit: (sorry Jon!)
I guess I'm asking if one can "enable" the functionality of the CallerMemberNameAttribute
in .NET 4.0 via redeclaration of the attribute in the proper namespace, much like one can "enable" LINQ query syntax in .NET 2.0 by proper declaration of the ExtensionAttribute
class. My strong suspicion is no, naturally...
Put yet another way: I want to know if I can benefit from the functionality of CallerMemberName
without upgrading to .NET 4.5/5
Hopefully that's more clear...
NinjaEdit #2: Sigh...version numbering conventions are confusing!