title: Accessing an array within a struct causes warnings with clang
body: <pre><code>struct test{
     char c_arr[1];
  };
  
  test array[1] = {{1}};
  
  test get(int index){
   return array[index];
  }
  
  int main(){
    char* a =  get(0).c_arr;
    return 0;
  }
  </code></pre>
  <p>Compiling this with <code>g++</code> has no warnings but with <code>clang++</code> prints the following:</p>
  <pre><code>warning: temporary whose address is used as value of local variable 'a' will be destroyed at the end of the full-expression
  </code></pre>
  <p>Is this incorrect? does <code>get(0).c_arr</code> not return a pointer to a global array?</p>
  <p>or does <code>get(0)</code> return a temporary variable and the compiler thinks <code>c_arr</code> is just an instance of it, and not global, by mistake?</p>
  <h2>Edit</h2>
  <p>Why passing this temp variable to a function works without warnings?</p>
  <pre><code>void call(char* in){}
  
  int main(){
    call(get(0).c_arr);
    return 0;
  }
  </code></pre>