[/ Copyright 2007 John Maddock. Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt). ] [section:is_stateless is_stateless] template struct is_stateless : public __tof {}; __inherit If T is a stateless type then inherits from __true_type, otherwise from __false_type. Type T must be a complete type. A stateless type is a type that has no storage and whose constructors and destructors are trivial. That means that `is_stateless` only inherits from __true_type if the following expression is `true`: ::boost::has_trivial_constructor::value && ::boost::has_trivial_copy::value && ::boost::has_trivial_destructor::value && ::boost::is_class::value && ::boost::is_empty::value __std_ref 3.9p10. __header ` #include ` or ` #include ` __compat Without some (as yet unspecified) help from the compiler, is_stateless will never report that a class or struct is stateless; this is always safe, if possibly sub-optimal. Currently (June 2015) compilers more recent than Visual C++ 8, Clang, GCC-4.3, Greenhills 6.0, Intel-11.0, and Codegear have the necessary compiler __intrinsics to ensure that this trait "just works". [endsect]