title: C++ concept member check type ambiquity with reference
body: <p>I am learning C++ concepts, and I have an obnoxious problem:</p>
  <p>I do not know how to differentiate between member variable being variable of type <code>int</code> and member variable being a <code>int&amp;</code>.</p>
  <p>Reason for this is that check I am using is using instance.member syntax and in C++ that returns a reference.</p>
  <p>Full example:</p>
  <pre><code>#include &lt;iostream&gt;
  #include &lt;concepts&gt;
  
  template&lt;typename T&gt;
  void print(T t) {
      std::cout &lt;&lt; &quot;generic&quot; &lt;&lt; std::endl;
  }
  
  template&lt;typename T&gt;
  requires requires(T t){
      {t.val} -&gt; std::same_as&lt;int&amp;&gt;;
  }
  void print(T t) {
      std::cout &lt;&lt; &quot;special&quot; &lt;&lt; std::endl;
  }
  
  struct S1{
      int bla;
  };
  
  struct S2{
     int val = 47;
  };
  int x = 47;
  struct S3{
      int&amp; val=x;
  };
  
  int main()
  {
      print(4.7);
      print(S1{});
      print(S2{});
      print(S3{});
  }
  </code></pre>
  <p>I wish <code>print(S3{})</code> would be handled by generic case, not the special one.
  Note that changing my <code>requires</code> stuff to:</p>
  <pre><code> {t.val} -&gt; std::same_as&lt;int&gt;;
  </code></pre>
  <p>makes <code>S2</code> not match the template so that does not work(like I said I think that member access in C++ returns a reference).</p>
  <p>Is there a way to fix this?</p>