https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89727

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |wrong-code
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2019-03-15
     Ever confirmed|0                           |1

--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> ---
.original shows the difference:

    struct B b;
  <<cleanup_point <<< Unknown tree: expr_stmt
  (void) std::basic_ostream<char>::operator<< ((struct __ostream_type *)
std::basic_ostream<char>::operator<< ((struct basic_ostream *)
std::basic_ostream<char>::operator<< (&cout, a.i), endl), flush) >>>>>;
  <<cleanup_point <<< Unknown tree: expr_stmt
  (void) std::basic_ostream<char>::operator<< ((struct basic_ostream *)
std::basic_ostream<char>::operator<< (&cout, _ZTWN1B1aE ()->i), endl) >>>>>;
  <<cleanup_point <<< Unknown tree: expr_stmt
  (void) std::basic_ostream<char>::operator<< ((struct basic_ostream *)
std::basic_ostream<char>::operator<< (&cout, a.i), endl) >>>>>;

note how we perform the access differently for B::a.i vs. b.a.i,
unexpected to me.

Reply via email to