// PR c++/32384 // { dg-do compile } struct A { typedef int T; T foo (); A () { foo ().~T (); } }; template struct B { typedef int T; T foo (); B () { foo ().~T (); } }; template struct C { T t; C () { t.~T (); } }; template struct D { typedef int T; S foo (); D () { foo ().~T(); } }; struct Z { Z () {} ~Z () {} }; A a; B b; C c1; C c2; D d;