2 // { dg-options "-Wparentheses" }
4 // Template version of Wparentheses-11.C.
12 foo (a + b & c); // { dg-warning "parentheses" "correct warning" }
15 foo (1 + 2 & c); // { dg-warning "parentheses" "correct warning" }
18 foo (1 + 2 & 3); // { dg-warning "parentheses" "correct warning" }
21 foo (a & b + c); // { dg-warning "parentheses" "correct warning" }
24 foo (1 & 2 + c); // { dg-warning "parentheses" "correct warning" }
27 foo (1 & 2 + 3); // { dg-warning "parentheses" "correct warning" }
30 foo (a - b & c); // { dg-warning "parentheses" "correct warning" }
33 foo (1 - 2 & c); // { dg-warning "parentheses" "correct warning" }
36 foo (1 - 2 & 3); // { dg-warning "parentheses" "correct warning" }
39 foo (a & b - c); // { dg-warning "parentheses" "correct warning" }
42 foo (1 & 2 - c); // { dg-warning "parentheses" "correct warning" }
45 foo (1 & 2 - 3); // { dg-warning "parentheses" "correct warning" }
48 foo (a < b & c); // { dg-warning "parentheses" "correct warning" }
51 foo (1 < 2 & c); // { dg-warning "parentheses" "correct warning" }
54 foo (1 < 2 & 3); // { dg-warning "parentheses" "correct warning" }
57 foo (a & b < c); // { dg-warning "parentheses" "correct warning" }
60 foo (1 & 2 < c); // { dg-warning "parentheses" "correct warning" }
63 foo (1 & 2 < 3); // { dg-warning "parentheses" "correct warning" }
66 foo (a == b & c); // { dg-warning "parentheses" "correct warning" }
69 foo (1 == 2 & c); // { dg-warning "parentheses" "correct warning" }
72 foo (1 == 2 & 3); // { dg-warning "parentheses" "correct warning" }
75 foo (a & b == c); // { dg-warning "parentheses" "correct warning" }
78 foo (1 & 2 == c); // { dg-warning "parentheses" "correct warning" }
81 foo (1 & 2 == 3); // { dg-warning "parentheses" "correct warning" }
84 foo (a != b & c); // { dg-warning "parentheses" "correct warning" }
87 foo (1 != 2 & c); // { dg-warning "parentheses" "correct warning" }
90 foo (1 != 2 & 3); // { dg-warning "parentheses" "correct warning" }
93 foo (a & b != c); // { dg-warning "parentheses" "correct warning" }
96 foo (1 & 2 != c); // { dg-warning "parentheses" "correct warning" }
99 foo (1 & 2 != 3); // { dg-warning "parentheses" "correct warning" }
104 template void bar<int> (int, int, int); // { dg-message "required" }