aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/g++.dg/torture/pr50672.C
blob: 614a35b6c8243f2ad7ffa6e0c25c564c0393ce3c (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 compile }

struct A
{
  bool isHint();
};
class B
{
  void makeLine( int *) const;
  void drawLine() const; A* to() const;
  void _print() const;
};
A a;
void  B::makeLine(int *p1) const
{
  if (a.isHint() && to()->isHint()) ;
  else {
      if (p1) B::drawLine(); else B::_print();
      return;
  }
  if (p1) B::drawLine(); else B::_print();
}