title: How to get expression from expression-bodied property c#
body: <p>I want to get the Expression of the Expression-bodied Property. I have no idea how to do that;/ Here is the simple code snippet:</p>
  <pre><code>class TestTest
  {
      public int A { get; set; } = 5;
  
      public int AX5 =&gt; A * 5;
  }
  public class Program
  {
  
      public static void Main()
      {
          var testObj = new TestTest();
  
          Expression&lt;Func&lt;TestTest, int&gt;&gt; expr = (t) =&gt; t.AX5;
      }
  
  }
  </code></pre>
  <p><a href="https://i.stack.imgur.com/jBrwR.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/jBrwR.png" alt="enter image description here" /></a></p>
  <p>This code works, but AX5 is not marked as Expression, it is the simple Int32 property.</p>
  <p>This is the result i want to get from the property:
  <a href="https://i.stack.imgur.com/6UeKs.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/6UeKs.png" alt="enter image description here" /></a></p>