add container_transform_traits specialization

This commit is contained in:
bolero-MURAKAMI 2016-04-03 16:08:09 +09:00
parent 0abea1678c
commit b4da8f5776
5 changed files with 43 additions and 0 deletions

View file

@ -38,6 +38,19 @@ namespace sprout {
return copied_type(SPROUT_FORWARD(Args, args)...);
}
};
//
// container_transform_traits
//
template<typename T>
struct container_transform_traits<sprout::complex<T> > {
public:
template<typename Type>
struct rebind_type {
public:
typedef sprout::complex<Type> type;
};
};
} // namespace sprout
#endif // #ifndef SPROUT_COMPLEX_CONTAINER_HPP

View file

@ -38,6 +38,19 @@ namespace sprout {
return copied_type(SPROUT_FORWARD(Args, args)...);
}
};
//
// container_transform_traits
//
template<typename T>
struct container_transform_traits<sprout::math::quaternion<T> > {
public:
template<typename Type>
struct rebind_type {
public:
typedef sprout::math::quaternion<Type> type;
};
};
} // namespace sprout
#endif // #ifndef SPROUT_MATH_QUATERNION_CONTAINER_HPP

View file

@ -38,6 +38,19 @@ namespace sprout {
return copied_type(SPROUT_FORWARD(Args, args)...);
}
};
//
// container_transform_traits
//
template<typename T>
struct container_transform_traits<sprout::optional<T> > {
public:
template<typename Type>
struct rebind_type {
public:
typedef sprout::optional<Type> type;
};
};
} // namespace sprout
#endif // #ifndef SPROUT_OPTIONAL_CONTAINER_HPP

View file

@ -1271,4 +1271,6 @@ namespace sprout {
}
} // namespace sprout
#include <sprout/string/container.hpp>
#endif // #ifndef SPROUT_STRING_STRING_HPP

View file

@ -670,4 +670,6 @@ namespace sprout {
}
} // namespace sprout
#include <sprout/valarray/container.hpp>
#endif // #ifndef SPROUT_VALARRAY_VALARRAY_HPP