Version: SMASH-3.3
smash::detail::is_stl_container< T > Struct Template Reference

#include <traits.h>

template<typename T>
struct smash::detail::is_stl_container< T >

Implementation of the type trait to infer if a type is an STL container.

This is the general case for types that are not STL containers.

Attention
This is at the moment meant to serve the SMASH codebase only and it is on purpose not to add all STL possible containers here. In particular, the goal is to implement the is_writable_to_stream trait in a general way since we need it in the Configuration class through the Key::as_yaml method, where the type streamed is totally generic and we need to avoid using the stream operator<< on types that do not support it. If SMASH is used as library and another container is needed, a specialization of the is_stl_container template can be easily added in smash::detail namespace.
Warning
The type std::array should NOT be added here as STL container. This would lead to an ambiguity in the is_writable_to_stream trait and would break compilation. In fact, it is standard to consider std::array as tuple-like and so it is done here.
Template Parameters
TThe type to be tested.

Definition at line 49 of file traits.h.

Inheritance diagram for smash::detail::is_stl_container< T >:

The documentation for this struct was generated from the following file: