1 // { dg-do compile } 2 // { dg-options "-Wparentheses" } 3 4 template <class x> 5 class z : x 6 { 7 public: zz()8 bool zz () { return false; } f()9 int f () { return zz () ? : 1; } // { dg-warning "omitted middle operand" } 10 }; 11 12 class t 13 { 14 }; 15 16 int main()17main () 18 { 19 z<t> x; 20 return x.f (); 21 } 22