partial-specialization
Template specialization with nested unspecialized type
I\'m having trouble working out the syntax for a neste开发者_JS百科d partial template specialization. I think that\'s the right way of putting it anyway. What I want is an as() function which returns[详细]
2023-04-01 03:35 分类:问答Avoiding duplication of function definitions in partial template specializations when using traits
How does one share common_fn() among all specializations (for Widget<A<T> > and Widget<B<T> >, no matter what T is) in the code below?[详细]
2023-03-29 18:33 分类:问答Tag dispatch versus static methods on partially specialised classes
Suppose I want to write a generic function void f<T>(), which does one thing if T is a POD type and another thing if T is non-POD (or any other arbitrary predicate).[详细]
2023-03-24 12:25 分类:问答Problem with C++ Partial Template Specialization
I have a situation similar to this: template<class A, class B> class MyClass<A, B> { ... static A RARELY_USED_A;[详细]
2023-03-20 20:24 分类:问答Partial template specialisation of a functor that's calling a member method of objects passed to it
I have the following functor and its partial specialisation template<class _T, typename _Return = void, typename _Arg = void>[详细]
2023-03-20 09:26 分类:问答Template parameters not used in partial specialization
I have the following code: template<typename T, typename Allocator = std::allocator<T> > class Carray {[详细]
2023-03-13 18:16 分类:问答Too few template-parameter-lists problem
Can anybody please tell me how to make the following pseudo-code compatible with GCC4? I wonder how it work开发者_运维问答s under MSVC...[详细]
2023-03-06 05:44 分类:问答Why is it disallowed for partial specialization in a non-type argument to use nested template parameters
I have this code template<int N, bool C = true> struct A; template<int N> struct A<N, !(N % 5)> {[详细]
2023-03-05 04:23 分类:问答c++ pimpl idiom : Implementation depending on a template parameter
In this question I unsuccessfully asked how to use different pimpl implementation depending on a template argument.[详细]
2023-02-19 08:06 分类:问答Inner class depending on a template argument
Consider next example : #include <iostream> #include <typeinfo> template< int N, typename T >[详细]
2023-02-19 05:53 分类:问答