title: {CallerMemberName} like Functionality for nameof() param
body: <p>I'm writing more library code and came across an annoyance - here is an example</p>
  
  <pre><code>public static TParam RequiredParam&lt;TParam&gt;(TParam param, string name) where TParam : class 
  {
    return param ?? throw new ArgumentNullException(name);
  }
  
  private readonly int _testInt;
  
  public TestClass(int testInt)
  {
    _testInt = RequiredParam(testInt, nameof(testInt));
  }
  </code></pre>
  
  <p>Basically I have to pass in the name in the usage</p>
  
  <p>What I want to have is:</p>
  
  <pre><code>public static TParam RequiredParam&lt;TParam&gt;(TParam param) where TParam : class 
  {
    return param ?? throw new ArgumentNullException(*NAME STILL GETS HERE SOMEHOW*);
  }
  
  private readonly int _testInt;
  
  public TestClass(int testInt)
  {
    _testInt = RequiredParam(testInt);
  }
  </code></pre>
  
  <p>Is there a better way? Back in the days of WPF I used to use [CallerMemberName]  like so:</p>
  
  <pre><code>private void PropertyChanged([CallerMemberName]string name = default)
  {
    PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(name));
  }
  </code></pre>
  
  <p>Does anyone know something similar to achieve the same result for this? Considering how often this library is called I don't mind stepping into post-build steps or whatever, but would prefer to avoid reflection for performance reasons.</p>
  
  <p>Edit - Made my objective clearer</p>