Added forward class declaration sequence diagram test case

This commit is contained in:
Bartek Kryza
2022-12-11 22:48:56 +01:00
parent fb2bc68d39
commit c7b80297d7
6 changed files with 100 additions and 2 deletions
+37
View File
@@ -0,0 +1,37 @@
#include <memory>
namespace clanguml {
namespace t20022 {
class B;
class A {
public:
A(std::unique_ptr<B> b);
void a();
std::unique_ptr<B> b_;
};
class B {
public:
void b() { }
};
A::A(std::unique_ptr<B> b)
: b_{std::move(b)}
{
}
void A::a() { b_->b(); }
int tmain()
{
A a{std::make_unique<B>()};
a.a();
return 0;
}
}
}