* auto-profile.c (afdo_annotate_cfg): Use update_max_bb_count.
[official-gcc.git] / gcc / testsuite / g++.dg / vect / pr44861.cc
blob763f493c35a408776b420ee04e6c30625b9b2c3f
1 // { dg-do compile }
3 bool f();
5 struct counted_base {
6 virtual void destroy() { }
7 void release() { if (f()) destroy(); }
8 };
10 struct shared_count {
11 shared_count() { }
12 ~shared_count() { if (pi) pi->release(); }
13 shared_count(shared_count& r) : pi(r.pi) { if (pi) pi->release(); }
14 counted_base* pi;
17 struct Foo;
19 struct shared_ptr {
20 Foo& operator*() { return *ptr; }
21 Foo* ptr;
22 shared_count refcount;
25 struct Bar {
26 Bar(Foo&, shared_ptr);
29 void g() {
30 shared_ptr foo;
31 new Bar(*foo, foo);