1 2 3 4 5 6 7 8 9 10 11 12
// PR c++/26577 struct A { A(const A&); A& operator=(const A&); void baz() volatile; }; void A::baz() volatile { *this; // { dg-warning "will not be accessed" } }