With .net 4.5 you can now retrieve caller’s information via the new API, the application of this feature is unlimited and the best part is that you can use this in release mode as well (good bye reflection).
As you can see the compiler converts the [caller]attributes with literals as it parses the file. The [caller]attributes can only be applied to parameters.
From MSDN:
By using Caller Info attributes, you can obtain information about the caller to a method. You can obtain file path of the source code, the line number in the source code, and the member name of the caller. This information is helpful for tracing, debugging, and creating diagnostic tools.
To obtain this information, you use attributes that are applied to optional parameters, each of which has a default value. The following table lists the Caller Info attributes that are defined in the System.Runtime.CompilerServices namespace:
Update: see one fine implementation of this feature i.e using caller information to implement INotifyPropertyChanged