summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.mike/p5469a.C
blob: 03a398469acecf8ef0b487e31c4d2a1b5d8e226f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
// { dg-do run  }
// prms-id: 5469

int count;

class A {
  A();
  A(const A&);
public:
  A(int) { ++count; }
  ~A() { --count; }
  int operator== (const A& r) { return 1; }
};

int main() {
  {
    A a (1);
    if (a == 2 || a == 1)
      ;
  }
  return count;
}