summary refs log tree commit diff stats
path: root/tests/cpp/23962.h
blob: 2d8147bfbd4f22bee7da70b009a8a6a4c75a0835 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#include <iostream>

struct Foo {

  Foo(int inX): x(inX) {
    std::cout << "Ctor Foo(" << x << ")\n";
  }
  ~Foo() {
    std::cout << "Destory Foo(" << x << ")\n";
  }

  void print() {
    std::cout << "Foo.x = " << x << '\n';
  }

  int x;
};