title: Is a member of an rvalue structure an rvalue or lvalue?
body: <p>A function call returning a structure is an rvalue expression, but what about its members?<br>
  This piece of code works well with my g++ compiler, but gcc gives a error saying "lvalue required as left operand of assignment":</p>
  
  <pre><code>struct A
  {
      int v;
  };
  
  struct A fun()
  {
      struct A tmp;
      return tmp;
  }
  
  int main()
  {
      fun().v = 1;
  }
  </code></pre>
  
  <p>gcc treats <code>fun().v</code> as rvalue, and I can understand that.<br>
  But g++ doesn't think the assignment expression is wrong. Does that mean fun1().v is lvalue in C++?<br>
  Now the problem is, I searched the C++98/03 standard, finding nothing telling about whether <code>fun().v</code> is lvalue or rvalue.<br>
  So, what is it?</p>