Daily bump.
[gcc.git] / gcc / testsuite / g++.dg / warn / Wtautological-compare4.C
blob96308f49a429d181924304206fc4bc271d625ab5
1 // PR c++/116534
2 // { dg-do compile }
3 // { dg-options "-Wall" }
5 template <class A>
6 struct Test {
7     bool foo(unsigned x, unsigned y) {
8         bool test = &a[x] == &b[y];
9         return test;
10     }
11     unsigned *a;
12     unsigned *b;
15 void
16 g ()
18   Test<int> t;
19   t.foo (0u, 1u);
20   t.foo (0u, 0u);