diff --git a/docs/test_cases.md b/docs/test_cases.md index f278cd02..50318d3a 100644 --- a/docs/test_cases.md +++ b/docs/test_cases.md @@ -45,6 +45,7 @@ * [t00044](./test_cases/t00044.md) - Test case for inner type aliases with parent class template args * [t00045](./test_cases/t00045.md) - Test case for root namespace handling * [t00046](./test_cases/t00046.md) - Test case for root namespace handling with packages + * [t00047](./test_cases/t00047.md) - Test case for recursive variadic template ## Sequence diagrams * [t20001](./test_cases/t20001.md) - Basic sequence diagram test case * [t20002](./test_cases/t20002.md) - Free function sequence diagram test case diff --git a/docs/test_cases/t00002_class.svg b/docs/test_cases/t00002_class.svg index 254d72fb..1faa9977 100644 --- a/docs/test_cases/t00002_class.svg +++ b/docs/test_cases/t00002_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,146 +9,106 @@ - - + + A - - - - - foo_a() = 0 : void - - - - - foo_c() = 0 : void - - - - - B - - + + + + + B + + + + foo_a() : void - - - - - - foo_a() : void - - - + + C - - - - - foo_c() : void - - - - - D - + + + + + D + - - - + + + - - as : std::vector<A*> + + as : std::vector<A *> - - - - - - - foo_a() : void - - - - - - - foo_c() : void - - - + + + foo_a() : void + + foo_c() : void + + E - + - - - + + + - - as : std::vector<A*> + + as : std::vector<A *> - - - - - - - foo_a() : void - - - - - - - foo_c() : void - - + + + foo_a() : void + + foo_c() : void + This is class A - + This is class B - - - This is class D - which is a little like B - and a little like C - - - + + + This is class D + which is a little like B + and a little like C + + + - - + + as - - - - - + + + + + as - - - + + + diff --git a/docs/test_cases/t00003.md b/docs/test_cases/t00003.md index b2f6ae96..e9d3d011 100644 --- a/docs/test_cases/t00003.md +++ b/docs/test_cases/t00003.md @@ -41,7 +41,7 @@ public: auto auto_method() { return 1; } auto double_int(const int i) { return 2 * i; } - auto sum(const double a, const double b) { return a + b; } + auto sum(const double a, const double b) { return a_ + b_ + c_; } auto default_int(int i = 12) { return i + 10; } std::string default_string(int i, std::string s = "abc") @@ -69,7 +69,7 @@ private: void private_method() { } int private_member; - int a, b, c; + int a_, b_, c_; }; int A::static_int = 1; diff --git a/docs/test_cases/t00003_class.svg b/docs/test_cases/t00003_class.svg index 16fb5bc5..ce94f5db 100644 --- a/docs/test_cases/t00003_class.svg +++ b/docs/test_cases/t00003_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,195 +9,115 @@ - - - - - A - + + + + + A + - + - + public_member : int - + - + - - static_int : int + + protected_member : int - + - + - - static_const_int : int const + + private_member : int - + - + - - auto_member : unsigned long const + + a_ : int - + - + - - protected_member : int + + b_ : int - + - - private_member : int + + c_ : int - + - + - - a : int + + static_int : int - + - + - - b : int + + static_const_int : const int - + - + - - c : int + + auto_member : const unsigned long - - - - - - - A() : void - - - - - - - A(int i) : void - - - - - - - A(A&& ) : void - - - - - - - A(A const& ) : void - - - - - - - ~A() : void - - - - - - - basic_method() : void - - - - - - - static_method() : int - - - - - - - const_method() const : void - - - - - - - auto_method() : int - - - - - - - double_int(int const i) : int - - - - - - - sum(double const a, double const b) : double - - - - - - - default_int(int i = 12) : int - - - - - - - default_string(int i, std::string s = "abc") : std::string - - - - - - - create_from_int(int i) : A - - - - - - - protected_method() : void - - - - - - - private_method() : void - - + + + A() = default : void + + A(int i) : void + + A(class A && ) = default : void + + A(const class A & ) = default : void + + ~A() = default : void + + basic_method() : void + + static_method() : int + + const_method() const : void + + auto_method() : int + + double_int(const int i) : int + + sum(const double a, const double b) : int + + default_int(int i = </home/bartek/devel/clang-uml-libtooling/tests/t00003/t00003.cc:26:30>) : int + + default_string(int i, std::string s = </home/bartek/devel/clang-uml-libtooling/tests/t00003/t00003.cc:27:55>) : std::string + + create_from_int(int i) : class A + + protected_method() : void + + private_method() : void + - - compare : std::function<bool(int const)> + + compare : std::function<bool (const int)> diff --git a/docs/test_cases/t00004_class.svg b/docs/test_cases/t00004_class.svg index 6a9563ba..5a684988 100644 --- a/docs/test_cases/t00004_class.svg +++ b/docs/test_cases/t00004_class.svg @@ -1,6 +1,6 @@ - + @@ -9,38 +9,28 @@ - - + + A - - - - - foo() const : void - - - - - foo2() const : void - - + + AA - - + + Lights @@ -50,23 +40,23 @@ Red - - + + AAA - + - + - + diff --git a/docs/test_cases/t00005_class.svg b/docs/test_cases/t00005_class.svg index d6c99079..3575da4e 100644 --- a/docs/test_cases/t00005_class.svg +++ b/docs/test_cases/t00005_class.svg @@ -1,6 +1,6 @@ - + @@ -9,238 +9,238 @@ - - + + A - - + + B - - + + C - - + + D - - + + E - - + + F - - + + G - - + + H - - + + I - - + + J - - + + K - - + + R - + - - - + + + - - some_int : int + + some_int : int - - - + + + - - some_int_pointer : int* + + some_int_pointer : int * - - - + + + - - some_int_pointer_pointer : int** + + some_int_pointer_pointer : int ** - - - + + + - - some_int_reference : int& + + some_int_reference : int & - - - + + + - - a : A + + a : A - - - + + + - - b : B* + + b : B * - - - + + + - - c : C& + + c : C & - - - + + + - - d : D const* + + d : const D * - - - + + + - - e : E const& + + e : const E & - - - + + + - - f : F&& + + f : F && - - - + + + - - g : G** + + g : G ** - - - + + + - - h : H*** + + h : H *** - - - + + + - - i : I*& + + i : I *& - - - + + + - - j : J volatile* + + j : volatile J * - - - + + + - - k : K* + + k : K * - - - + + + +a - - + + +b - + +c - + +d - + +e - + +f - + +g - + +h - - + + +i - - + + +j - + +k diff --git a/docs/test_cases/t00006_class.svg b/docs/test_cases/t00006_class.svg index 432a00df..cb6186b9 100644 --- a/docs/test_cases/t00006_class.svg +++ b/docs/test_cases/t00006_class.svg @@ -1,6 +1,6 @@ - + @@ -9,136 +9,136 @@ - - + + A - - + + B - - + + C - - + + D - - + + E - - + + F - - + + G - - + + H - - + + I - - + + J - - + + K - - + + L - - + + M - - + + N - - + + NN - - + + NNN - - + + custom_container @@ -146,15 +146,15 @@ T - + - + data : std::vector<T> - + custom_container @@ -162,160 +162,160 @@ E - - + + R - + - - - + + + - - a : std::vector<A> + + a : std::vector<A> - - - + + + - - b : std::vector<B*> + + b : std::vector<B *> - - - + + + - - c : std::map<int,C> + + c : std::map<int,C> - - - + + + - - d : std::map<int,D*> + + d : std::map<int,D *> - - - + + + - - e : custom_container<E> + + e : custom_container<E> - - - + + + - - f : std::vector<std::vector<F>> + + f : std::vector<std::vector<F>> - - - + + + - - g : std::map<int,std::vector<G*>> + + g : std::map<int,std::vector<G *>> - - - + + + - - h : std::array<H,10> + + h : std::array<H,10> - - - + + + - - i : std::array<I*,5> + + i : std::array<I *,5> - - - + + + - - j : J[10] + + j : J[10] - - - + + + - - k : K*[20] + + k : K *[20] - - - + + + - - lm : std::vector<std::pair<L,M>> + + lm : std::vector<std::pair<L,M>> - - - + + + - - ns : std::tuple<N,NN,NNN> + + ns : std::tuple<N,NN,NNN> - - + + - + - - + + +a - + +b - - + + +c - - + + +d - - + + +e - - + + +f - + +g - + +h - + +i - + +j - + +k - + lm - - + + lm - - + + ns - - + + ns - - + + ns diff --git a/docs/test_cases/t00007_class.svg b/docs/test_cases/t00007_class.svg index 1378af33..99e4cb3b 100644 --- a/docs/test_cases/t00007_class.svg +++ b/docs/test_cases/t00007_class.svg @@ -1,6 +1,6 @@ - + @@ -9,66 +9,66 @@ - - + + A - - + + B - - + + C - - + + R - + - + a : std::unique_ptr<A> - + - + b : std::shared_ptr<B> - + - + c : std::weak_ptr<C> - + +a - + +b - + +c diff --git a/docs/test_cases/t00008_class.svg b/docs/test_cases/t00008_class.svg index 5c10a00a..84a4104b 100644 --- a/docs/test_cases/t00008_class.svg +++ b/docs/test_cases/t00008_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,8 +9,8 @@ - - + + A @@ -18,51 +18,51 @@ T,P,CMP,int N - + - + value : T - + - - pointer : T* + + pointer : T * - + - - reference : T& + + reference : T & - + - + values : std::vector<P> - + - + ints : std::array<int,N> - + - + comparator : CMP - - + + Vector @@ -70,73 +70,63 @@ T - + - + values : std::vector<T> - - - - - B - - T,C<> - + + + + + B + + T,C<> + - - - + + + - - template_template : C<T> + + template_template : C<T> - - - - - B - - int,Vector - - - - - - - D - + + + + + B + + int,Vector + + + + + + + D + - + - + ints : B<int,Vector> - - - - - - - D(std::tuple<Items...>* ) : void - - - - - - - add(int i) : void - - - - - - - ints + + + add(int i) : void + + D(std::tuple<Items...> * ) : void + + + + + + ints diff --git a/docs/test_cases/t00009_class.svg b/docs/test_cases/t00009_class.svg index 31d3c3ce..d262481b 100644 --- a/docs/test_cases/t00009_class.svg +++ b/docs/test_cases/t00009_class.svg @@ -1,6 +1,6 @@ - + @@ -9,8 +9,8 @@ - - + + A @@ -18,15 +18,15 @@ T - + - + value : T - + A @@ -34,7 +34,7 @@ int - + A @@ -42,7 +42,7 @@ std::string - + A @@ -50,50 +50,50 @@ std::vector<std::string> - - + + B - + - - - + + + - - aint : A<int> + + aint : A<int> - - - + + + - - astring : A<std::string>* + + astring : A<std::string> * - - - + + + - - avector : A<std::vector<std::string>>& + + avector : A<std::vector<std::string>> & - - + + - + - + - + aint - + astring - + avector diff --git a/docs/test_cases/t00010_class.svg b/docs/test_cases/t00010_class.svg index 1046597e..86791c6e 100644 --- a/docs/test_cases/t00010_class.svg +++ b/docs/test_cases/t00010_class.svg @@ -1,6 +1,6 @@ - + @@ -9,8 +9,8 @@ - - + + A @@ -18,22 +18,22 @@ T,P - + - + first : T - + - + second : P - + A @@ -41,8 +41,8 @@ T,std::string - - + + B @@ -50,15 +50,15 @@ T - + - + astring : A<T,std::string> - + B @@ -66,30 +66,30 @@ int - - + + C - + - + aintstring : B<int> - + - + astring - + - + aintstring diff --git a/docs/test_cases/t00011.md b/docs/test_cases/t00011.md index a12358c1..430f8dae 100644 --- a/docs/test_cases/t00011.md +++ b/docs/test_cases/t00011.md @@ -33,7 +33,7 @@ template class D { }; class A { -private: +public: void foo() { } friend class B; friend class external::C; diff --git a/docs/test_cases/t00011_class.svg b/docs/test_cases/t00011_class.svg index 04cf83d2..3b680e69 100644 --- a/docs/test_cases/t00011_class.svg +++ b/docs/test_cases/t00011_class.svg @@ -1,6 +1,6 @@ - + @@ -9,8 +9,8 @@ - - + + D @@ -18,56 +18,46 @@ T - + - + value : T - - + + A - - - - - - + foo() : void - - + + B - + - - m_a : A* + + m_a : A * - - - - - - foo() : void - - + + foo() : void + - + «friend» - + m_a diff --git a/docs/test_cases/t00012_class.svg b/docs/test_cases/t00012_class.svg index c1fb3b94..ca517867 100644 --- a/docs/test_cases/t00012_class.svg +++ b/docs/test_cases/t00012_class.svg @@ -1,6 +1,6 @@ - + @@ -9,8 +9,8 @@ - - + + A @@ -18,56 +18,56 @@ T,Ts... - + - + value : T - + - + values : std::variant<Ts...> - - + + B - int Is... + int... Is - + - + ints : std::array<int,sizeof...(Is)> - - + + C - T,int Is... + T,int... Is - + - + ints : std::array<T,sizeof...(Is)> - + A @@ -75,7 +75,7 @@ int,std::string,float - + A @@ -83,7 +83,7 @@ int,std::string,bool - + B @@ -91,7 +91,7 @@ 3,2,1 - + B @@ -99,7 +99,7 @@ 1,1,1,1 - + C @@ -107,79 +107,79 @@ std::map<int,std::vector<std::vector<std::vector<std::string>>>>,3,3,3 - - + + R - + - + a1 : A<int,std::string,float> - + - + a2 : A<int,std::string,bool> - + - + b1 : B<3,2,1> - + - + b2 : B<1,1,1,1> - + - + c1 : C<std::map<int,std::vector<std::vector<std::vector<std::string>>>>,3,3,3> - + Long template annotation - + - + - + - + - + - + a1 - + a2 - + b1 - + b2 - + c1 diff --git a/docs/test_cases/t00013_class.svg b/docs/test_cases/t00013_class.svg index acbd03e4..37491693 100644 --- a/docs/test_cases/t00013_class.svg +++ b/docs/test_cases/t00013_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,295 +9,235 @@ - - - - - ABCD::F - - T - + + + + + ABCD::F + + T + - - - + + + - - f : T + + f : T - - - - - - A - + + + + + ABCD::F + + int + + + + + + + A + - - - + + + - - a : int + + a : int - - - - - - B - + + + + + + B + - - - + + + - - b : int + + b : int - - - - - - C - + + + + + + C + - - - + + + - - c : int + + c : int - - - - - - D - + + + + + + D + - + - + d : int - - - - + + + print(class R * r) : void + + + + + E + + T + - - print(R* r) : void + + + - - - - - E - - T - + + e : T - - - + + + + + + G + + T,Args... + - - e : T + + + - - - - - - G - - T,Args... - + + g : T - - - + + + - - g : T + + args : std::tuple<Args...> - - - + + + + + E + + int + + + + + + G + + int,float,std::string + + + + + + E + + std::string + + + + + + + R + - - args : std::tuple<Args...> + + + - - - - - E - - int - - - - - - F - - int - - - - - - G - - int,float,std::string - - - - - - E - - std::string - - - - - - - R - + + gintstring : G<int,float,std::string> - - - + + + - - gintstring : G<int,float,std::string> + + estring : E<std::string> - - - - - - estring : E<std::string> - - - - - - - - get_a(A* a) : int - - - - - - - get_b(B& b) : int - - - - - - - get_const_b(B const& b) : int - - - - - - - get_c(C c) : int - - - - - - - get_d(D&& d) : int - - - - - - - get_d2(D&& d) : int - - - - - - - get_e(E<T> e) : T - - - - - - - get_int_e(E<int> const& e) : int - - - - - - - get_int_e2(E<int>& e) : int - - - - - - - get_f(F<T> const& f) : T - - - - - - - get_int_f(F<int> const& f) : int - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - gintstring - - - - estring + + + get_a(struct A * a) : int + + get_b(struct B & b) : int + + get_const_b(const struct B & b) : int + + get_c(struct C c) : int + + get_d(struct D && d) : int + + get_d2(struct D && d) : int + + get_int_e(const E<int> & e) : int + + get_int_e2(E<int> & e) : int + + get_int_f(const F<int> & f) : int + + get_e(E<T> e) : T + + get_f(const F<T> & f) : T + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + gintstring + + + + estring diff --git a/docs/test_cases/t00014_class.svg b/docs/test_cases/t00014_class.svg index 0e2866a6..b36b977b 100644 --- a/docs/test_cases/t00014_class.svg +++ b/docs/test_cases/t00014_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,365 +9,341 @@ - - - - - A - - T,P - + + + + + A + + T,P + - - - + + + - - t : T + + t : T - - - + + + - - p : P + + p : P - - - - - - B - + + + + + + B + - - - + + + - - value : std::string + + value : std::string - - - - - A - - T,std::string - - - - - - A - - T,std::unique_ptr<std::string> - - - - - - A - - long,T - - - - - - A - - double,T - - - - - - A - - long,bool - - - - - - A - - double,bool - - - - - - A - - long,float - - - - - - A - - double,float - - - - - - A - - bool,std::string - - - - - - A - - float,std::unique_ptr<std::string> - - - - - - A - - int,std::string - - - - - - A - - std::string,std::string - - - - - - A - - char,std::string - - - - - - A - - wchar_t,std::string - - - - - - - R - + + + + + A + + T,std::string + + + + + + A + + T,std::unique_ptr<std::string> + + + + + + A + + long,T + + + + + + A + + double,T + + + + + + A + + long,bool + + + + + + A + + double,bool + + + + + + A + + long,float + + + + + + A + + double,float + + + + + + A + + bool,std::string + + + + + + A + + float,std::unique_ptr<std::string> + + + + + + A + + int,std::string + + + + + + A + + std::string,std::string + + + + + + + R + - - - + + + - - bapair : PairPairBA<bool> + + bapair : PairPairBA<bool> - - - + + + - - abool : APtr<bool> + + abool : APtr<bool> - - - + + + - - aboolfloat : AAPtr<bool,float> + + aboolfloat : AAPtr<bool,float> - - - + + + - - afloat : ASharedPtr<float> + + afloat : ASharedPtr<float> - - - + + + - - boolstring : A<bool,std::string> + + boolstring : A<bool,std::string> - - - + + + - - floatstring : AStringPtr<float> + + floatstring : AStringPtr<float> - - - + + + - - intstring : AIntString + + intstring : AIntString - - - + + + - - stringstring : AStringString + + stringstring : AStringString - - - + + + - - bstringstring : BStringString + + bstringstring : BStringString - - - + + + - - bs : BVector + + bs : BVector - - - + + + - - bs2 : BVector2 + + bs2 : BVector2 - - - + + + - - cb : SimpleCallback<ACharString> + + cb : SimpleCallback<ACharString> - - - + + + - - gcb : GenericCallback<R::AWCharString> + + gcb : GenericCallback<R::AWCharString> - - - + + + - - vcb : VoidCallback + + vcb : VoidCallback - - - + + + - - vps : VectorPtr<B> + + vps : VectorPtr<B> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - bapair - - - - bapair - - - - bs - - - - bs2 - - - - vps - - - - - - abool - - - - aboolfloat - - - - - - aboolfloat - - - - - - afloat - - - - boolstring - - - - floatstring - - - - intstring - - - - stringstring - - - - bstringstring - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + bapair + + + + bapair + + + + bs + + + + bs2 + + + + vps + + + + + + abool + + + + aboolfloat + + + + + + aboolfloat + + + + + + afloat + + + + boolstring + + + + floatstring + + + + intstring + + + + stringstring + + + + bstringstring diff --git a/docs/test_cases/t00015_class.svg b/docs/test_cases/t00015_class.svg index 7bf579f5..8f9456f8 100644 --- a/docs/test_cases/t00015_class.svg +++ b/docs/test_cases/t00015_class.svg @@ -1,6 +1,6 @@ - + @@ -9,51 +9,51 @@ - - + + ns1::A - - + + ns1::ns2_v0_9_0::A - - + + ns1::Anon - - + + ns3::ns1::ns2::Anon - - + + ns3::B - + - + - + diff --git a/docs/test_cases/t00016.md b/docs/test_cases/t00016.md index ede95857..1f433fa7 100644 --- a/docs/test_cases/t00016.md +++ b/docs/test_cases/t00016.md @@ -25,11 +25,15 @@ template struct is_numeric { enum { value = false }; }; +template <> struct is_numeric { + enum { value = true }; +}; + template <> struct is_numeric { enum { value = true }; }; -template <> struct is_numeric { +template <> struct is_numeric { enum { value = true }; }; diff --git a/docs/test_cases/t00016_class.svg b/docs/test_cases/t00016_class.svg index dfbfb93b..d4804d13 100644 --- a/docs/test_cases/t00016_class.svg +++ b/docs/test_cases/t00016_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,71 +9,85 @@ - - - - - is_numeric<> - - - value : enum - + + + + + is_numeric<> + + + value : enum + - - + + is_numeric - char + float value : enum - - - - - is_numeric - - unsigned char - - - value : enum - + + + + + is_numeric + + char + + + value : enum + - - - - - is_numeric - - int - - - value : enum - + + + + + is_numeric + + unsigned int + + + value : enum + - - - - - is_numeric - - bool - - - value : enum - + + + + + is_numeric + + int + + + value : enum + - - - - - - - - + + + + + is_numeric + + bool + + + value : enum + + + + + + + + + + + + diff --git a/docs/test_cases/t00017_class.svg b/docs/test_cases/t00017_class.svg index db62f262..9386e419 100644 --- a/docs/test_cases/t00017_class.svg +++ b/docs/test_cases/t00017_class.svg @@ -1,6 +1,6 @@ - + @@ -9,176 +9,171 @@ - - + + A - - + + B - - + + C - - + + D - - + + E - - + + F - - + + G - - + + H - - + + I - - + + J - - + + K - - + + R - + - - - + + + - - some_int : int + + some_int : int - - - + + + - - some_int_pointer : int* + + some_int_pointer : int * - - - + + + - - some_int_pointer_pointer : int** + + some_int_pointer_pointer : int ** - - - + + + - - some_int_reference : int& + + some_int_reference : int & - - - - - - - R(int& some_int, C& cc, E const& ee, F&& ff, I*& ii) : void - - + + + R(int & some_int, class C & cc, const class E & ee, class F && ff, class I *& ii) : void + - + -c - + - + -e - + - + -f - + - + -i - - + + -a - + -b - + -d - + -g - + -h - + -j - + -k diff --git a/docs/test_cases/t00018.md b/docs/test_cases/t00018.md index b6cd8197..12e990f2 100644 --- a/docs/test_cases/t00018.md +++ b/docs/test_cases/t00018.md @@ -7,7 +7,6 @@ diagrams: t00018_class: type: class glob: - - ../../tests/t00018/**.h - ../../tests/t00018/**.cc using_namespace: - clanguml::t00018 diff --git a/docs/test_cases/t00018_class.svg b/docs/test_cases/t00018_class.svg index ba7283f7..656cbf7d 100644 --- a/docs/test_cases/t00018_class.svg +++ b/docs/test_cases/t00018_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,127 +9,65 @@ - - - - - impl::widget - + + + + + impl::widget + - - - + + + - - n : int + + n : int - - - - + + + draw(const widget & w) const : void + + draw(const widget & w) : void + + widget(int n) : void + + + + + widget + - - draw(widget const& w) const : void - - - - - - - draw(widget const& w) : void - - - - - - - widget(int n) : void - - - - - - widget - - - + - + pImpl : std::unique_ptr<impl::widget> - - - - - - - draw() const : void - - - - - - - draw() : void - - - - - - - shown() const : bool - - - - - - - widget(int ) : void - - - - - - - ~widget() : void - - - - - - - widget(widget&& ) : void - - - - - - - widget(widget const& ) : void - - - - - - - operator=(widget&& ) : widget& - - - - - - - operator=(widget const& ) : widget& - - - - - - - - - pImpl + + + draw() const : void + + draw() : void + + shown() const : _Bool + + widget(int ) : void + + ~widget() : void + + widget(class widget && ) : void + + widget(const class widget & ) : void + + operator=(class widget && ) : class widget & + + operator=(const class widget & ) : class widget & + + + + + + pImpl diff --git a/docs/test_cases/t00019.md b/docs/test_cases/t00019.md index 4f51ff13..150684b1 100644 --- a/docs/test_cases/t00019.md +++ b/docs/test_cases/t00019.md @@ -7,7 +7,6 @@ diagrams: t00019_class: type: class glob: - - ../../tests/t00019/**.h - ../../tests/t00019/**.cc using_namespace: - clanguml::t00019 diff --git a/docs/test_cases/t00019_class.svg b/docs/test_cases/t00019_class.svg index c4ecc0cc..8e4d54d8 100644 --- a/docs/test_cases/t00019_class.svg +++ b/docs/test_cases/t00019_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,197 +9,142 @@ - - - - - Layer2 - - LowerLayer - - + + + + + Base + + + + Base() = default : void + + ~Base() = default : void + + m1() : int + + m2() : std::string - - - + + + + + Layer1 + + LowerLayer + + + + m1() : int + + m2() : std::string - - all_calls_count() const : int + + + + + Layer2 + + LowerLayer + + + + all_calls_count() const : int - - - - - Base - - + + + + + Layer3 + + LowerLayer + - - - + + + - - Base() : void + + m_m1_calls : int - - - + + + - - ~Base() : void + + m_m2_calls : int - - - + + + m1() : int + + m2() : std::string + + m1_calls() const : int + + m2_calls() const : int + + + + Layer3 + + Base + + + + + + Layer2 + + Layer3<Base> + + + + + + Layer1 + + Layer2<Layer3<Base>> + + + + + + + A + - - m1() : int + + + - - - + + layers : std::unique_ptr<Layer1<Layer2<Layer3<Base>>>> - - m2() : std::string - - - - - - Layer1 - - LowerLayer - - - - - - - - - m1() : int - - - - - - - m2() : std::string - - - - - - Layer3 - - LowerLayer - - - - - - - - m_m1_calls : int - - - - - - - m_m2_calls : int - - - - - - - - m1() : int - - - - - - - m2() : std::string - - - - - - - m1_calls() const : int - - - - - - - m2_calls() const : int - - - - - Layer3 - - Base - - - - - - Layer2 - - Layer3<Base> - - - - - - Layer1 - - Layer2<Layer3<Base>> - - - - - - - A - - - - - - - - layers : std::unique_ptr<Layer1<Layer2<Layer3<Base>>>> - - - - - - - - - - - - - - - - - - - - - - - - - - layers + + + + + + + + + + + + + + + + + + + + + + + + + layers diff --git a/docs/test_cases/t00020_class.svg b/docs/test_cases/t00020_class.svg index 9cef149e..3adeab7c 100644 --- a/docs/test_cases/t00020_class.svg +++ b/docs/test_cases/t00020_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,195 +9,125 @@ - - - - - ProductA - - + + + + + ProductA + + + + ~ProductA() = default : void + + sell(int price) const = 0 : _Bool - - - + + + + + ProductA1 + + + + sell(int price) const : _Bool - - ~ProductA() : void + + + + + ProductA2 + + + + sell(int price) const : _Bool - - - + + + + + ProductB + + + + ~ProductB() = default : void + + buy(int price) const = 0 : _Bool - - sell(int price) const = 0 : bool - - - - - - ProductA1 - - - - - - - - - sell(int price) const : bool - - - - - - ProductA2 - - - - - - - - - sell(int price) const : bool - - - - - - ProductB - - - - - - - - - ~ProductB() : void - - - - - - - buy(int price) const = 0 : bool - - - - - - ProductB1 - - - - - + + + + + ProductB1 + + + buy(int price) const : _Bool - - buy(int price) const : bool + + + + + ProductB2 + + + + buy(int price) const : _Bool - - - - - ProductB2 - - + + + + + AbstractFactory + + + + make_a() const = 0 : std::unique_ptr<ProductA> + + make_b() const = 0 : std::unique_ptr<ProductB> - - - + + + + + Factory1 + + + + make_a() const : std::unique_ptr<ProductA> + + make_b() const : std::unique_ptr<ProductB> - - buy(int price) const : bool + + + + + Factory2 + + + + make_a() const : std::unique_ptr<ProductA> + + make_b() const : std::unique_ptr<ProductB> - - - - - AbstractFactory - - - - - - - - - make_a() const = 0 : std::unique_ptr<ProductA> - - - - - - - make_b() const = 0 : std::unique_ptr<ProductB> - - - - - - Factory1 - - - - - - - - - make_a() const : std::unique_ptr<ProductA> - - - - - - - make_b() const : std::unique_ptr<ProductB> - - - - - - Factory2 - - - - - - - - - make_a() const : std::unique_ptr<ProductA> - - - - - - - make_b() const : std::unique_ptr<ProductB> - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + diff --git a/docs/test_cases/t00021_class.svg b/docs/test_cases/t00021_class.svg index 517a3034..40d14608 100644 --- a/docs/test_cases/t00021_class.svg +++ b/docs/test_cases/t00021_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,184 +9,119 @@ - - - - - Visitor - - + + + + + Visitor + + + + ~Visitor() = default : void + + visit_A(const class A & item) const = 0 : void + + visit_B(const class B & item) const = 0 : void - - - + + + + + Visitor1 + + + + visit_A(const class A & item) const : void + + visit_B(const class B & item) const : void - - ~Visitor() : void + + + + + Visitor2 + + + + visit_A(const class A & item) const : void + + visit_B(const class B & item) const : void - - - + + + + + Visitor3 + + + + visit_A(const class A & item) const : void + + visit_B(const class B & item) const : void - - visit_A(A const& item) const = 0 : void + + + + + Item + + + + ~Item() = default : void + + accept(const class Visitor & visitor) const = 0 : void - - - - - - visit_B(B const& item) const = 0 : void - - - - - - Visitor1 - - - - - - - - - visit_A(A const& item) const : void - - - - - - - visit_B(B const& item) const : void - - - - - - Visitor2 - - - - - - - - - visit_A(A const& item) const : void - - - - - - - visit_B(B const& item) const : void - - - - - - Visitor3 - - - - - - - - - visit_A(A const& item) const : void - - - - - - - visit_B(B const& item) const : void - - - - - - Item - - - - - - - - - ~Item() : void - - - - - - - accept(Visitor const& visitor) const = 0 : void - - - - - - A - - - - - + + + + + A + + + accept(const class Visitor & visitor) const : void - - accept(Visitor const& visitor) const : void + + + + + B + + + + accept(const class Visitor & visitor) const : void - - - - - B - - - - - - - - - accept(Visitor const& visitor) const : void - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/docs/test_cases/t00022_class.svg b/docs/test_cases/t00022_class.svg index 0fd3d41d..fb285977 100644 --- a/docs/test_cases/t00022_class.svg +++ b/docs/test_cases/t00022_class.svg @@ -1,6 +1,6 @@ - + @@ -9,82 +9,47 @@ - - + + A - - - - - template_method() : void - - - - - method1() = 0 : void - - - - - method2() = 0 : void - - + + A1 - - - - - method1() : void - - - - - method2() : void - - + + A2 - - - - - method1() : void - - - - - method2() : void - + - + diff --git a/docs/test_cases/t00023_class.svg b/docs/test_cases/t00023_class.svg index 35c23a4d..ea911c62 100644 --- a/docs/test_cases/t00023_class.svg +++ b/docs/test_cases/t00023_class.svg @@ -1,6 +1,6 @@ - + @@ -9,111 +9,76 @@ - - - - - Strategy - - + + + + + Strategy + + + + ~Strategy() = default : void + + algorithm() = 0 : void - - - - - - ~Strategy() : void - - - - - - - algorithm() = 0 : void - - - + + StrategyA - - - - - algorithm() : void - - + + StrategyB - - - - - algorithm() : void - - + + StrategyC - - - - - algorithm() : void - - + + Context - + - + m_strategy : std::unique_ptr<Strategy> - - - - - - Context(std::unique_ptr<Strategy> strategy) : void - - - - - - - apply() : void - - + + Context(std::unique_ptr<Strategy> strategy) : void + + apply() : void + - + - + - + - + m_strategy diff --git a/docs/test_cases/t00024_class.svg b/docs/test_cases/t00024_class.svg index 01e0c4be..0e8537e9 100644 --- a/docs/test_cases/t00024_class.svg +++ b/docs/test_cases/t00024_class.svg @@ -1,6 +1,6 @@ - + @@ -9,126 +9,76 @@ - - - - - Target - - + + + + + Target + + + + ~Target() = 0 : void + + m1() = 0 : void + + m2() = 0 : void - - - - - - ~Target() : void - - - - - - - m1() = 0 : void - - - - - - - m2() = 0 : void - - - + + Target1 - - - - - m1() : void - - - - - m2() : void - - + + Target2 - - - - - m1() : void - - - - - m2() : void - - + + Proxy - + - + m_target : std::shared_ptr<Target> - - - - - - Proxy(std::shared_ptr<Target> target) : void - - - - - - - m1() : void - - - - - - - m2() : void - - - - + + Proxy(std::shared_ptr<Target> target) : void + + m1() : void + + m2() : void + + + - + - + m_target - + diff --git a/docs/test_cases/t00025_class.svg b/docs/test_cases/t00025_class.svg index 868f1af7..c4e44621 100644 --- a/docs/test_cases/t00025_class.svg +++ b/docs/test_cases/t00025_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,141 +9,106 @@ - - + + Target1 - - - - - m1() : void - - - - - m2() : void - - - - - Target2 - - + + + + + Target2 + + + + m1() : void + + m2() : void - - - + + + + + Proxy + + T + - - m1() : void + + + - - - + + m_target : std::shared_ptr<T> - - m2() : void + + + Proxy<T>(std::shared_ptr<T> target) : void + + m1() : void + + m2() : void + + + + Proxy + + Target1 + + + + + + Proxy + + Target2 + + + + + + + ProxyHolder + - - - - - Proxy - - T - + + + - - - + + proxy1 : Proxy<Target1> - - m_target : std::shared_ptr<T> + + + - - - - + + proxy2 : Proxy<Target2> - - Proxy(std::shared_ptr<T> target) : void - - - - - - - m1() : void - - - - - - - m2() : void - - - - - Proxy - - Target1 - - - - - - Proxy - - Target2 - - - - - - - ProxyHolder - - - - - - - - proxy1 : Proxy<Target1> - - - - - - - proxy2 : Proxy<Target2> - - - - - - - - - - - - - - proxy1 - - - - proxy2 + + + + + + + + + + + + + proxy1 + + + + proxy2 diff --git a/docs/test_cases/t00026_class.svg b/docs/test_cases/t00026_class.svg index ecefd172..8eef98b1 100644 --- a/docs/test_cases/t00026_class.svg +++ b/docs/test_cases/t00026_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,39 +9,29 @@ - - - - - Memento - - T - + + + + + Memento + + T + - - - + + + - - m_value : T + + m_value : T - - - - - - - Memento(T&& v) : void - - - - - - - value() const : T - - - + + + Memento<T>(T && v) : void + + value() const : T + + Originator @@ -49,51 +39,26 @@ T - + - + m_value : T - - - - - - Originator(T&& v) : void - - - - - - - memoize_value() const : Memento<T> - - - - - - - load(Memento<T> const& m) : void - - - - - - - print() const : void - - - - - - - set(T&& v) : void - - - + + Originator<T>(T && v) : void + + memoize_value() const : Memento<T> + + load(const Memento<T> & m) : void + + print() const : void + + set(T && v) : void + + Caretaker @@ -101,29 +66,19 @@ T - + - + m_mementos : std::unordered_map<std::string,Memento<T>> - - - - - - state(std::string const& n) : Memento<T>& - - - - - - - set_state(std::string const& s, Memento<T>&& m) : void - - + + state(const std::string & n) : Memento<T> & + + set_state(const std::string & s, Memento<T> && m) : void + Caretaker @@ -131,7 +86,7 @@ std::string - + Originator @@ -139,45 +94,41 @@ std::string - - + + StringMemento - + - + caretaker : Caretaker<std::string> - + - + originator : Originator<std::string> - - - - - - - - m_mementos - + + + + + - + - + caretaker - + originator diff --git a/docs/test_cases/t00027_class.svg b/docs/test_cases/t00027_class.svg index 13ce6e7f..82db525d 100644 --- a/docs/test_cases/t00027_class.svg +++ b/docs/test_cases/t00027_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,30 +9,20 @@ - - - - - Shape - - - - - + + + + + Shape + + - - display() = 0 : void - - - + ~Shape() = default : void - - ~Shape() : void - - - + + Line @@ -40,81 +30,56 @@ T<>... - - - - - display() : void - - - - - Text - - T<>... - - + + + + + Text + + T<>... + + + + display() : void - - - + + + + + ShapeDecorator + + + + display() = 0 : void - - display() : void + + + + + Color + + T + + + + display() : void - - - - - ShapeDecorator - - + + + + + Weight + + T + + + + display() : void - - - - - - display() = 0 : void - - - - - - Color - - T - - - - - - - - - display() : void - - - - - - Weight - - T - - - - - - - - - display() : void - - + Line @@ -122,7 +87,7 @@ Color,Weight - + Line @@ -130,89 +95,89 @@ Color - - - - Text - - Color,Weight - - - - - - Text - - Color - - - - - - - Window - + + + + Text + + Color,Weight + + + + + + Text + + Color + + + + + + + Window + - - - + + + - - border : Line<Color,Weight> + + border : Line<Color,Weight> - - - + + + - - divider : Line<Color> + + divider : Line<Color> - - - + + + - - title : Text<Color,Weight> + + title : Text<Color,Weight> - - - + + + - - description : Text<Color> + + description : Text<Color> - - - - - - - - - - + + + + + + + + + + - + - - - - - - - - border - - - - divider - - - - title - - - - description + + + + + + + + border + + + + divider + + + + title + + + + description diff --git a/docs/test_cases/t00028_class.svg b/docs/test_cases/t00028_class.svg index ca0941e1..6f9f9ee3 100644 --- a/docs/test_cases/t00028_class.svg +++ b/docs/test_cases/t00028_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,212 +9,186 @@ - - - - - A - - + + + + + A + + - - - A class note. - - - A class note. - - - - - B - - + + + A class note. + + + + + B + + - - - B class note. - - - B class note. - - - - - C - - + + + B class note. + + + + + C + + - - - C class note. - - - C class note. - - - - - D - - + + + C class note. + + + + + D + + - - - D - class - note. - - - D - class - note. - - - - - E - - T - + + + D + class + note. + + + + + E + + T + - - - + + + - - param : T + + param : T - - - - E template class note. - - - - - G - - + + + + E template class note. + + + + + G + + - - - - - F - - one - two - three - + + + + + F + + one + two + three + - - - F enum note. - - - F enum note. - - - - E - - int - - - - - - - R - + + + F enum note. + + + + E + + int + + + + + + + R + - - - + + + - - aaa : A + + aaa : A - - - + + + - - bbb : B* + + bbb : B * - - - + + + - - ccc : C& + + ccc : C & - - - + + + - - ddd : std::vector<std::shared_ptr<D>> + + ddd : std::vector<std::shared_ptr<D>> - - - + + + - - eee : E<int> + + eee : E<int> - - - + + + - - ggg : G** + + ggg : G ** - - - - - - - R(C& c) : void - - - - R class note. - - - R class note. - - - - - - - - - - - ccc - - - - aaa - - - - bbb - - - - ddd - - - - eee - - - - ggg + + + R(class C & c) : void + + + R class note. + + + + + + + + + + ccc + + + + aaa + + + + bbb + + + + ddd + + + + eee + + + + ggg diff --git a/docs/test_cases/t00029_class.svg b/docs/test_cases/t00029_class.svg index a4566b70..312954f9 100644 --- a/docs/test_cases/t00029_class.svg +++ b/docs/test_cases/t00029_class.svg @@ -1,6 +1,6 @@ - + @@ -9,16 +9,16 @@ - - + + A - - + + C @@ -26,16 +26,16 @@ T - + - + param : T - - + + E @@ -45,72 +45,72 @@ three - - + + G1 - - + + G2 - - + + G3 - - + + G4 - - + + R - + - + g1 : G1 - + - - g3 : G3& + + g3 : G3 & - + - + g4 : std::shared_ptr<G4> - + g1 - + g4 diff --git a/docs/test_cases/t00030.md b/docs/test_cases/t00030.md index 46b3717c..0ce62ed0 100644 --- a/docs/test_cases/t00030.md +++ b/docs/test_cases/t00030.md @@ -36,6 +36,9 @@ class C { class D { }; +class E { +}; + struct R { /// @uml{association[]} A aaa; @@ -48,6 +51,9 @@ struct R { /// @uml{association[:1]} D ddd; + + /// @uml{aggregation[:1]} + E *eee; }; } // namespace t00030 diff --git a/docs/test_cases/t00030_class.svg b/docs/test_cases/t00030_class.svg index f07103f5..65a9ed92 100644 --- a/docs/test_cases/t00030_class.svg +++ b/docs/test_cases/t00030_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,94 +9,114 @@ - - - - - A - - + + + + + A + + - - - - - B - - + + + + + B + + - - - - - C - - + + + + + C + + - - - - - D - - + + + + + D + + - - - - - R - + + + + + E + + - - - + + + + + R + - - aaa : A + + + - - - + + aaa : A - - bbb : std::vector<B> + + + - - - + + bbb : std::vector<B> - - ccc : std::vector<C> + + + - - - + + ccc : std::vector<C> - - ddd : D + + + - - - - - aaa - - - - bbb - 0..1 - 1..* - - - - ccc - 0..1 - 1..5 - - - - ddd - 1 + + ddd : D + + + + + + + eee : E * + + + + + + aaa + + + + bbb + 0..1 + 1..* + + + + ccc + 0..1 + 1..5 + + + + ddd + 1 + + + + eee + 1 diff --git a/docs/test_cases/t00031_class.svg b/docs/test_cases/t00031_class.svg index 0882f265..bf4b8ea0 100644 --- a/docs/test_cases/t00031_class.svg +++ b/docs/test_cases/t00031_class.svg @@ -1,33 +1,33 @@ - + - + - + - - - + + + A - - + + B @@ -37,8 +37,8 @@ three - - + + @@ -47,23 +47,23 @@ T - + - + ttt : T - - + + D - + C @@ -71,57 +71,57 @@ int - - + + R - + - - aaa : A* + + aaa : A * - + - + bbb : std::vector<B> - + - + ccc : C<int> - + - - ddd : D* + + ddd : D * - + - + aaa - + bbb - + ccc - + ddd diff --git a/docs/test_cases/t00032_class.svg b/docs/test_cases/t00032_class.svg index c7701f06..8aa50ced 100644 --- a/docs/test_cases/t00032_class.svg +++ b/docs/test_cases/t00032_class.svg @@ -1,6 +1,6 @@ - + @@ -9,69 +9,54 @@ - - + + Base - - + + TBase - - + + A - - - - - operator()() : void - - + + B - - - - - operator()() : void - - + + C - - - - - operator()() : void - - + + Overload @@ -79,15 +64,15 @@ T,L,Ts... - + - + counter : L - + Overload @@ -95,42 +80,42 @@ TBase,int,A,B,C - - + + R - + - + overload : Overload<TBase,int,A,B,C> - + - + - + - + - + - + - + - + - + - + - + overload diff --git a/docs/test_cases/t00033_class.svg b/docs/test_cases/t00033_class.svg index abac44ae..078c5e0f 100644 --- a/docs/test_cases/t00033_class.svg +++ b/docs/test_cases/t00033_class.svg @@ -1,6 +1,6 @@ - + @@ -9,8 +9,8 @@ - - + + A @@ -18,16 +18,16 @@ T - + - + aaa : T - - + + B @@ -35,16 +35,16 @@ T - + - + bbb : T - - + + C @@ -52,30 +52,30 @@ T - + - + ccc : T - - + + D - + - + ddd : int - + C @@ -83,7 +83,7 @@ D - + B @@ -91,7 +91,7 @@ std::unique_ptr<C<D>> - + A @@ -99,34 +99,34 @@ B<std::unique_ptr<C<D>>> - - + + R - + - + abc : A<B<std::unique_ptr<C<D>>>> - + - + - + - + - + - + - + abc diff --git a/docs/test_cases/t00034_class.svg b/docs/test_cases/t00034_class.svg index cc45d72c..422f2778 100644 --- a/docs/test_cases/t00034_class.svg +++ b/docs/test_cases/t00034_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,107 +9,103 @@ - - - - - Void - - - - - + + + + + Void + + - - - operator==(Void const& ) const : bool - - - + operator==(const struct Void & ) const : _Bool + operator!=(const struct Void & ) const : _Bool - - operator!=(Void const& ) const : bool + + + + + lift_void + + T + + - - - - - lift_void - - T - - + + + + + lift_void + + void + + - - - - - lift_void - - void - - + + + + + drop_void + + T + + - - - - - drop_void - - T - - + + + + + drop_void + + Void + + - - - - - drop_void - - Void - - + + + + + A + + - - - - - A - - + + + + + R + - - - - - R - + + + - - - + + la : lift_void_t<A> * - - la : lift_void_t<A>* + + + - - - + + lv : lift_void_t<void> * - - lv : lift_void_t<void>* - - - - - - - - - - - - la + + + + + + + + + la + + + + la + + + + lv diff --git a/docs/test_cases/t00035_class.svg b/docs/test_cases/t00035_class.svg index 90d8b83a..d9d1fcea 100644 --- a/docs/test_cases/t00035_class.svg +++ b/docs/test_cases/t00035_class.svg @@ -1,6 +1,6 @@ - + @@ -9,40 +9,40 @@ - - + + Top - - + + Left - - + + Center - - + + Bottom - - + + Right diff --git a/docs/test_cases/t00036.md b/docs/test_cases/t00036.md index 9d8250b1..e8b17089 100644 --- a/docs/test_cases/t00036.md +++ b/docs/test_cases/t00036.md @@ -44,7 +44,9 @@ struct B { namespace ns2 { namespace ns22 { -struct C; +// TODO: Fix for incomplete struct C declaration "struct C;" +struct C { +}; } } diff --git a/docs/test_cases/t00036_class.svg b/docs/test_cases/t00036_class.svg index df8ed6d0..d8bd90b0 100644 --- a/docs/test_cases/t00036_class.svg +++ b/docs/test_cases/t00036_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,23 +9,23 @@ - + ns1 - + ns11 - + ns111 - + ns2 - + ns22 - - + + E @@ -34,24 +34,24 @@ yellow - - - - - A - - T - + + + + + A + + T + - - - + + + - - a : T + + a : T - - + + A @@ -59,34 +59,34 @@ int - - + + B - + - + a_int : A<int> - - + + C - - - + a_int + + diff --git a/docs/test_cases/t00037_class.svg b/docs/test_cases/t00037_class.svg index e373aac2..bdb55c0c 100644 --- a/docs/test_cases/t00037_class.svg +++ b/docs/test_cases/t00037_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,86 +9,85 @@ - - - - - ST - + + + + + ST + + - - - + + + - - dimensions : «anonymous» + + dimensions : struct (unnamed struct at /home/bartek/devel/clang-uml-libtooling/tests/t00037/t00037.cc:5:5) - - - - - - <<anonymous>> - + + + + + <<anonymous>> + - - - + + + - - t : double + + t : double - - - + + + - - x : double + + x : double - - - + + + - - y : double + + y : double - - - + + + - - z : double + + z : double - - - - - - A - + + + + + + A + - - - + + + - - st : ST + + st : ST - - - - - - - A() : void - - - - - - - - - st + + + A() : void + + + + dimensions + + + + + + + + st diff --git a/docs/test_cases/t00038.md b/docs/test_cases/t00038.md index 006ea523..7a916875 100644 --- a/docs/test_cases/t00038.md +++ b/docs/test_cases/t00038.md @@ -53,7 +53,8 @@ struct key_t { std::string key; }; -template struct map; +template struct map { +}; using namespace thirdparty::ns1; diff --git a/docs/test_cases/t00038_class.svg b/docs/test_cases/t00038_class.svg index d4dac5da..42cebdc9 100644 --- a/docs/test_cases/t00038_class.svg +++ b/docs/test_cases/t00038_class.svg @@ -1,6 +1,6 @@ - + @@ -9,8 +9,8 @@ - - + + thirdparty::ns1::color_t @@ -20,16 +20,16 @@ blue - - + + thirdparty::ns1::E - - + + property_t @@ -39,47 +39,47 @@ property_c - - + + A - - + + B - - + + C - - + + key_t - + - + key : std::string - - + + map @@ -88,8 +88,8 @@ - - + + map @@ -98,8 +98,8 @@ - - + + map @@ -108,8 +108,8 @@ - - + + map @@ -118,8 +118,8 @@ - - + + map @@ -128,31 +128,31 @@ - + - + - + - + - + - + - + - + - + - + - + - + - + diff --git a/docs/test_cases/t00039_class.svg b/docs/test_cases/t00039_class.svg index 4fdb9e55..ff266cb8 100644 --- a/docs/test_cases/t00039_class.svg +++ b/docs/test_cases/t00039_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,186 +9,186 @@ - - + + C - - + + D - - + + E - - + + CD - - + + DE - - + + CDE - - + + A - - + + AA - - - - - AAA - + + + + + AAA + - - - + + + - - b : B* + + b : B * - - - + + + ns2::AAAA - - - - - ns3::F - - T - + + + + + ns3::F + + T + - - - + + + - - t : T* + + t : T * - - - - - - ns3::FF - - T,M - + + + + + + ns3::FF + + T,M + - - - + + + - - m : M* + + m : M * - - - - - - ns3::FE - - T,M - + + + + + + ns3::FE + + T,M + - - - + + + - - m : M* + + m : M * - - - - - - ns3::FFF - - T,M,N - + + + + + + ns3::FFF + + T,M,N + - - - + + + - - n : N* + + n : N * - - + + - + - + - + - + - + - + - + - + - + - - - - - - + + + + + + diff --git a/docs/test_cases/t00040_class.svg b/docs/test_cases/t00040_class.svg index 36c2e202..d507bf49 100644 --- a/docs/test_cases/t00040_class.svg +++ b/docs/test_cases/t00040_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,76 +9,61 @@ - - + + A - + - + ii_ : int - - - - - - get_a() : int - - - + + get_a() : int + + AA - - + + AAA - + - - b : B* + + b : B * - - - + + get_aaa() : int + + + + + R + + + + foo(struct A * a) : void - - get_aaa() : int - - - - - - R - - - - - - - - - foo(A* a) : void - - + - + diff --git a/docs/test_cases/t00041_class.svg b/docs/test_cases/t00041_class.svg index 203c2289..b65652da 100644 --- a/docs/test_cases/t00041_class.svg +++ b/docs/test_cases/t00041_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,116 +9,116 @@ - - - - - R - - + + + + + R + + - - - - - D - + + + + + D + - - - + + + - - rr : RR* + + rr : RR * - - - + + + E - - + + F - - - - - RR - + + + + + RR + - - - + + + - - e : E* + + e : E * - - - + + + - - f : F* + + f : F * - - - + + + RRR - - - - - ns1::N - - + + + + + ns1::N + + - - - - - ns1::NN - - + + + + + ns1::NN + + - - - - - ns1::NM - - + + + + + ns1::NM + + - - + + rr - + +e - + +f - - - + + + - - - - + + + + diff --git a/docs/test_cases/t00042_class.svg b/docs/test_cases/t00042_class.svg index a77f41d6..0cadb0e5 100644 --- a/docs/test_cases/t00042_class.svg +++ b/docs/test_cases/t00042_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,46 +9,95 @@ - - - - - A - - T - + + + + + A + + T + - - - + + + - - a : T + + a : T - - - - - - B - - T,K - + + + + + + A + + void + - - - + + + - - b : T + + a : void * - - - + + + + + + B + + T,K + - - bb : K + + + - + + b : T + + + + + + + bb : K + + + + + + A + + double + + + + + + A + + std::string + + + + + + B + + int,float + + + + + + + + + + diff --git a/docs/test_cases/t00043_class.svg b/docs/test_cases/t00043_class.svg index bfa8e273..27c1aebc 100644 --- a/docs/test_cases/t00043_class.svg +++ b/docs/test_cases/t00043_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,189 +9,139 @@ - + dependants - - - dependencies - - - - - A - - + + + dependencies + + + + + A + + - - - - - B - - + + + + + B + + + + b(struct dependants::A * a) : void - - - + + + + + BB + + + + bb(struct dependants::A * a) : void - - b(dependants::A* a) : void + + + + + C + + + + c(struct dependants::B * b) : void - - - - - BB - - + + + + + D + + + + d(struct dependants::C * c) : void + + dd(struct dependants::BB * bb) : void - - - + + + + + E + + + + e(struct dependants::D * d) : void - - bb(dependants::A* a) : void + + + + + G + + - - - - - C - - + + + + + GG + + - - - + + + + + H + + + + h(struct dependencies::G * g) : void + + hh(struct dependencies::GG * gg) : void - - c(dependants::B* b) : void + + + + + I + + + + i(struct dependencies::H * h) : void - - - - - D - - + + + + + J + + + + i(struct dependencies::I * i) : void - - - - - - d(dependants::C* c) : void - - - - - - - dd(dependants::BB* bb) : void - - - - - - E - - - - - - - - - e(dependants::D* d) : void - - - - - - G - - - - - - - - GG - - - - - - - - H - - - - - - - - - h(dependencies::G* g) : void - - - - - - - hh(dependencies::GG* gg) : void - - - - - - I - - - - - - - - - i(dependencies::H* h) : void - - - - - - J - - - - - - - - - i(dependencies::I* i) : void - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + diff --git a/docs/test_cases/t00044_class.svg b/docs/test_cases/t00044_class.svg index 067865fc..ae19c2c4 100644 --- a/docs/test_cases/t00044_class.svg +++ b/docs/test_cases/t00044_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,65 +9,72 @@ - - - - - sink - - T - - + + + + signal_handler + + ,A + + + + + + + sink + + clanguml::t00044::signal_handler<,type-parameter-0-2> + + + + sink<signal_handler<type-parameter-0-0 (type-parameter-0-1...), type-parameter-0-2> >(sink<signal_handler<type-parameter-0-0 (type-parameter-0-1...), type-parameter-0-2> >::signal_t & sh) : void - - - - - signal_handler - - T,A - - + + + - - - - - sink - - Ret,Args...,A - + + signal : sink<signal_handler<type-parameter-0-0 (type-parameter-0-1...),type-parameter-0-2>>::signal_t * - - - + + + + + signal_handler + + Ret(Args...),A + + - - signal : signal_t* + + + + + sink + + T + + - - - - - - - sink(sink<signal_handler<type-parameter-0-0 (type-parameter-0-1...), type-parameter-0-2>>::signal_t& sh) : void - - - - - signal_handler - - - - - - - signal_handler - - Ret,Args...,A - - + + + + + signal_handler + + T,A + + + + + + + + signal + + + + diff --git a/docs/test_cases/t00045_class.svg b/docs/test_cases/t00045_class.svg index 86f29a53..7ccdabb8 100644 --- a/docs/test_cases/t00045_class.svg +++ b/docs/test_cases/t00045_class.svg @@ -1,6 +1,6 @@ - + @@ -9,174 +9,169 @@ - - + + A - - + + AA - - + + AAA - - - - - AAAA - - T - + + + + + AAAA + + T + - - - + + + - - t : T + + t : T - - - + + + ns1::A - - + + ns1::ns2::A - - + + ns1::ns2::B - - + + ns1::ns2::C - - + + ns1::ns2::D - - + + ns1::ns2::E - - - - - ns1::ns2::AAA - - + + + + + ns1::ns2::AAA + + - - + + ns1::ns2::R - + - - - + + + - - a : ns1::ns2::A* + + a : ns1::ns2::A * - - - + + + - - ns1_a : ns1::A* + + ns1_a : ns1::A * - - - + + + - - ns1_ns2_a : ns1::ns2::A* + + ns1_ns2_a : ns1::ns2::A * - - - + + + - - root_a : ::A* + + root_a : ::A * - - - - - - - foo(AA& aa) : void - - + + + foo(AA & aa) : void + - + - + - + - + + + +a - + ns1_ns2_a - + ns1_a - + root_a - + «friend» - - diff --git a/docs/test_cases/t00046_class.svg b/docs/test_cases/t00046_class.svg index 9b13c8c0..b2613a0b 100644 --- a/docs/test_cases/t00046_class.svg +++ b/docs/test_cases/t00046_class.svg @@ -1,6 +1,6 @@ - + - + @@ -9,150 +9,148 @@ - - - ns1 - - - ns2 - - - - - A - - + + + ns1 + + + ns2 + + + __gnu_cxx + + + + + A + + - - - - - A - - + + + + + A + + - - - - - B - - + + + + + B + + - - - - - C - - + + + + + C + + - - - - - D - - + + + + + D + + - - - - - E - - + + + + + E + + - - - - - R - + + + + + R + - - - + + + - - a : ns1::ns2::A* + + a : ns1::ns2::A * - - - + + + - - ns1_a : ns1::A* + + ns1_a : ns1::A * - - - + + + - - ns1_ns2_a : ns1::ns2::A* + + ns1_ns2_a : ns1::ns2::A * - - - + + + - - root_a : ::A* + + root_a : ::A * - - - + + + - - i : std::vector<std::uint8_t> + + i : std::vector<std::uint8_t> - - - - + + + foo(AA & aa) : void + + + + + A + + - - foo(AA& aa) : void + + + + + AA + + - - - - - A - - - - - - - - AA - - - - - - - - - - - - - - +a - - - - ns1_ns2_a - - - - ns1_a - - - - root_a - - + + + + + + + + + + + + + +a + + + + ns1_ns2_a + + + + ns1_a + + + + root_a diff --git a/docs/test_cases/t00047.md b/docs/test_cases/t00047.md new file mode 100644 index 00000000..b6a90b2a --- /dev/null +++ b/docs/test_cases/t00047.md @@ -0,0 +1,47 @@ +# t00047 - Test case for recursive variadic template +## Config +```yaml +compilation_database_dir: .. +output_directory: puml +diagrams: + t00047_class: + type: class + glob: + - ../../tests/t00047/t00047.cc + using_namespace: clanguml::t00047 + include: + namespaces: + - clanguml::t00047 +``` +## Source code +File t00047.cc +```cpp +#include + +namespace clanguml { +namespace t00047 { + +template struct conditional_t; + +template struct conditional_t { + using type = Else; +}; + +template +struct conditional_t { + using type = Result; +}; + +template +struct conditional_t { + using type = typename conditional_t::type; +}; + +template +using conditional = typename conditional_t::type; + +} +} +``` +## Generated UML diagrams +![t00047_class](./t00047_class.svg "Test case for recursive variadic template") diff --git a/docs/test_cases/t00047_class.svg b/docs/test_cases/t00047_class.svg new file mode 100644 index 00000000..3b84fb8b --- /dev/null +++ b/docs/test_cases/t00047_class.svg @@ -0,0 +1,59 @@ + + + + + + + + + + + + + + + + conditional_t + + Else + + + + + + + + conditional_t + + std::true_type,Result,Tail... + + + + + + + + conditional_t + + std::false_type,Result,Tail... + + + + + + + + conditional_t + + Ts... + + + + + + + + + + + diff --git a/docs/test_cases/t30001_package.svg b/docs/test_cases/t30001_package.svg index bb931bba..60630241 100644 --- a/docs/test_cases/t30001_package.svg +++ b/docs/test_cases/t30001_package.svg @@ -1,6 +1,6 @@ - + @@ -9,67 +9,67 @@ - - + + A - - + + AA - - + + B - - + + AA - - + + AAA - - + + BBB - - + + BB - - + + AAA - - + + BBB - - + + BB - + A AAA note... - + This is namespace AA in namespace A - + This is namespace AA in namespace B - - - + + + diff --git a/docs/test_cases/t30002.md b/docs/test_cases/t30002.md index 900a31ad..d4245e5d 100644 --- a/docs/test_cases/t30002.md +++ b/docs/test_cases/t30002.md @@ -91,6 +91,14 @@ namespace A15 { struct CO { }; } +namespace A16 { +struct CP { +}; +} +namespace A17 { +struct CR { +}; +} } namespace B::BB::BBB { class CBA : public A::AA::A6::CF { @@ -100,11 +108,14 @@ public: std::shared_ptr cc_; std::map> *cd_; std::array co_; + static A::AA::A16::CP *cp_; CBA() = default; CBA(A::AA::A14::CN *cn) { } + friend A::AA::A17::CR; + template CBA(std::tuple &items) { } void ce(const std::vector /*ce_*/) { } @@ -112,7 +123,7 @@ public: std::shared_ptr cg() { return {}; } template - void ch(std::map> & /*ch_*/) + void ch(std::map> &ch_) { } diff --git a/docs/test_cases/t30002_package.svg b/docs/test_cases/t30002_package.svg index ae16c0d0..c5975580 100644 --- a/docs/test_cases/t30002_package.svg +++ b/docs/test_cases/t30002_package.svg @@ -1,6 +1,6 @@ - + - + @@ -9,135 +9,149 @@ - - + + A - - + + AA - - - - B + + + + B - - - - BB + + + + BB - - - - A1 + + + + A1 - - - - A2 + + + + A2 - - - - A3 + + + + A3 - - - - A4 + + + + A4 - - - - A5 + + + + A5 - - - - A6 + + + + A6 - - - - A7 + + + + A7 - - - - A8 + + + + A8 - - - - A9 + + + + A9 - - + + + + A10 + + + + + A11 + + + - A10 + A12 - - + + - A11 + A13 - - + + - A12 + A14 - - + + - A13 + A15 - - + + - A14 + A16 - - + + - A15 + A17 - - - - BBB + + + + BBB - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/docs/test_cases/t30003_package.svg b/docs/test_cases/t30003_package.svg index 64d91d3d..759eeeca 100644 --- a/docs/test_cases/t30003_package.svg +++ b/docs/test_cases/t30003_package.svg @@ -1,6 +1,6 @@ - + - + @@ -9,39 +9,41 @@ - - - - ns1 + + + + ns1 - - - - ns3 - «deprecated» + + + + ns3 + «deprecated» - - - - ns1 + + + + ns1 - - - - ns2_v1_0_0 + + + + ns2_v1_0_0 - - - - ns2_v0_9_0 - «deprecated» + + + + ns2_v0_9_0 + «deprecated» - - - - ns2 + + + + ns2 - - + + + + diff --git a/docs/test_cases/t30004_package.svg b/docs/test_cases/t30004_package.svg index f25bfb47..24f6e29f 100644 --- a/docs/test_cases/t30004_package.svg +++ b/docs/test_cases/t30004_package.svg @@ -1,6 +1,6 @@ - + @@ -9,46 +9,46 @@ - - + + A - + Package AAA. - + Package BBB. - + CCCC package note. - + We skipped DDD. - - + + AAA - - + + BBB - - + + CCC - - + + EEE - - - - + + + + diff --git a/docs/test_cases/t30005_package.svg b/docs/test_cases/t30005_package.svg index c931151f..43efcf50 100644 --- a/docs/test_cases/t30005_package.svg +++ b/docs/test_cases/t30005_package.svg @@ -1,6 +1,6 @@ - + @@ -9,54 +9,54 @@ - - + + A - - + + AA - - + + B - - + + BB - - + + C - - + + CC - - + + AAA - - + + BBB - - + + CCC - + - + diff --git a/docs/test_cases/t30006_package.svg b/docs/test_cases/t30006_package.svg index 19b8d404..ac0e5638 100644 --- a/docs/test_cases/t30006_package.svg +++ b/docs/test_cases/t30006_package.svg @@ -1,6 +1,6 @@ - + @@ -9,28 +9,28 @@ - - + + B - - + + A - - + + C - + Top A note. - - + + - + diff --git a/docs/test_cases/t30007_package.svg b/docs/test_cases/t30007_package.svg index a9e74825..05c1c022 100644 --- a/docs/test_cases/t30007_package.svg +++ b/docs/test_cases/t30007_package.svg @@ -1,6 +1,6 @@ - + @@ -9,33 +9,33 @@ - - + + A - - + + B - - + + AA - - + + C - + Compare layout with t30006. - - + + - + diff --git a/docs/test_cases/t30008_package.svg b/docs/test_cases/t30008_package.svg index 18e07f28..eab67365 100644 --- a/docs/test_cases/t30008_package.svg +++ b/docs/test_cases/t30008_package.svg @@ -1,6 +1,6 @@ - + @@ -9,53 +9,53 @@ - - + + dependants - - + + dependencies - - + + A - - + + B - - + + C - - + + D - - + + E - - + + F - + - + - + - + diff --git a/docs/test_cases/t40001.md b/docs/test_cases/t40001.md index cd37a223..8fff7d03 100644 --- a/docs/test_cases/t40001.md +++ b/docs/test_cases/t40001.md @@ -12,13 +12,13 @@ diagrams: - ../../tests/t40001/**/*.cc - ../../tests/t40001/**/*.h # Render the paths relative to this directory - relative_to: ../../tests/t40001 + relative_to: ../../../tests/t40001 # Include also external system headers generate_system_headers: true include: # Include only headers belonging to these paths paths: - - ../../tests/t40001 + - ../../../tests/t40001 plantuml: before: - "' t40001 test include diagram" diff --git a/docs/test_cases/t40001_include.svg b/docs/test_cases/t40001_include.svg index 5d5d3bce..4ab1ec8f 100644 --- a/docs/test_cases/t40001_include.svg +++ b/docs/test_cases/t40001_include.svg @@ -1,6 +1,6 @@ - + - + @@ -9,58 +9,58 @@ - + src - + include - + lib1 - - + + t40001.cc - - + + t40001_include1.h - - + + lib1.h - - - string - + + + string + vector - - - cppast/cpp_preprocessor.hpp - - - This is a lib1 include dir - + + + clang/Lex/Lexer.h + + + This is a lib1 include dir + This is a t40001_include1.h include file - - - + + + - + - + - - - - - - + + + + + + diff --git a/docs/test_cases/t40002.md b/docs/test_cases/t40002.md index 04dfc0c2..ebea7abf 100644 --- a/docs/test_cases/t40002.md +++ b/docs/test_cases/t40002.md @@ -12,15 +12,15 @@ diagrams: - ../../tests/t40002/**/*.cc - ../../tests/t40002/**/*.h # Render the paths relative to this directory - relative_to: ../../tests/t40002 + relative_to: ../../../tests/t40002 include: # Include only files belonging to these paths paths: - - ../../tests/t40002 + - ../../../tests/t40002 exclude: paths: # Exclude single header - - ../../tests/t40002/include/lib2/lib2_detail.h + - ../../../tests/t40002/include/lib2/lib2_detail.h plantuml: before: - "' t40002 test include diagram" diff --git a/docs/test_cases/t40002_include.svg b/docs/test_cases/t40002_include.svg index 58be2c91..d0bf10da 100644 --- a/docs/test_cases/t40002_include.svg +++ b/docs/test_cases/t40002_include.svg @@ -1,6 +1,6 @@ - + @@ -9,58 +9,58 @@ - + src - + lib1 - + lib2 - + include - + lib1 - + lib2 - - + + t40002.cc - - + + lib1.cc - - + + lib2.cc - - + + lib1.h - - + + lib2.h - + - + - + - + - + diff --git a/docs/test_cases/t40003.md b/docs/test_cases/t40003.md index 18d51585..1bc7bc15 100644 --- a/docs/test_cases/t40003.md +++ b/docs/test_cases/t40003.md @@ -12,13 +12,14 @@ diagrams: - ../../tests/t40003/include/**/*.h - ../../tests/t40003/src/**/*.cc # Render the paths relative to this directory - relative_to: ../../tests/t40003 + relative_to: ../../../tests/t40003 include: - # Include only files belonging to these paths + # Include only files which depend on t1.h dependants: - - ../../tests/t40003/include/dependants/t1.h + - ../../../tests/t40003/include/dependants/t1.h + # and dependencies of t2.cc dependencies: - - ../../tests/t40003/src/dependencies/t2.cc + - ../../../tests/t40003/src/dependencies/t2.cc plantuml: before: - "' t40003 test include diagram" diff --git a/docs/test_cases/t40003_include.svg b/docs/test_cases/t40003_include.svg index 53e73ed2..f688196f 100644 --- a/docs/test_cases/t40003_include.svg +++ b/docs/test_cases/t40003_include.svg @@ -1,6 +1,6 @@ - + @@ -9,84 +9,84 @@ - + include - + dependants - + dependencies - + src - + dependants - + dependencies - - + + t3.h - - + + t2.h - - + + t1.h - - + + t3.h - - + + t2.h - - + + t1.h - - + + t5.h - - + + t1.cc - - + + t2.cc - + - + - + - + - + - + - + - + diff --git a/tests/t90000/test_case.h b/tests/t90000/test_case.h index 425d5dc9..3cfb23a8 100644 --- a/tests/t90000/test_case.h +++ b/tests/t90000/test_case.h @@ -22,7 +22,7 @@ TEST_CASE("t90000", "[test-case][config]") auto diagram = config.diagrams["t90000_class"]; - auto model = generate_class_diagram(db, diagram); + auto model = generate_class_diagram(*db, diagram); REQUIRE(model->name() == "t90000_class"); diff --git a/tests/test_cases.cc b/tests/test_cases.cc index d44c7ab1..6090872d 100644 --- a/tests/test_cases.cc +++ b/tests/test_cases.cc @@ -265,7 +265,7 @@ using namespace clanguml::test::matchers; //// //// Other tests (e.g. configuration file) //// -//#include "t90000/test_case.h" +#include "t90000/test_case.h" // // Main test function