Adding template class specialization sequence diagram test case

This commit is contained in:
Bartek Kryza
2022-11-21 23:56:02 +01:00
parent f3aec40b2a
commit 4513e17275
9 changed files with 640 additions and 13 deletions

30
tests/t20006/t20006.cc Normal file
View File

@@ -0,0 +1,30 @@
#include <string>
namespace clanguml {
namespace t20006 {
template <typename T> struct A {
T a(T arg) { return arg; }
T a1(T arg) { return arg; }
};
template <typename T> struct B {
T b(T arg) { return a_.a(arg); }
A<T> a_;
};
template <> struct B<std::string> {
std::string b(std::string arg) { return arg; }
A<std::string> a_;
};
void tmain()
{
B<int> bint;
B<std::string> bstring;
bint.b(1);
bstring.b("bstring");
}
}
}