VCCC  2024.05
VisualCamp Common C++ library
copy_template.hpp
Go to the documentation of this file.
1 //
2 // Created by YongGyu Lee on 5/16/24.
3 //
4 
5 #ifndef VCCC_TYPE_TRAITS_COPY_TEMPLATE_HPP_
6 #define VCCC_TYPE_TRAITS_COPY_TEMPLATE_HPP_
7 
9 
10 namespace vccc {
11 
14 
15 template<typename From, template<typename...> class To, template<typename, typename...> class Proj = type_identity_t>
17 
18 template<template<typename...> class From, typename... T, template<typename...> class To, template<typename, typename...> class Proj>
19 struct copy_template<From<T...>, To, Proj> {
20  using type = To<Proj<T>...>;
21 };
22 
23 template<typename From, template<typename...> class To, template<typename, typename...> class Proj = type_identity_t>
25 
27 
28 } // namespace vccc
29 
30 #endif // VCCC_TYPE_TRAITS_COPY_TEMPLATE_HPP_
typename type_identity< T >::type type_identity_t
Definition: type_identity.hpp:22
typename copy_template< From, To, Proj >::type copy_template_t
Definition: copy_template.hpp:24
Definition: directory.h:12
To< Proj< T >... > type
Definition: copy_template.hpp:20
Definition: copy_template.hpp:16