mirror of
https://github.com/boostorg/utility.git
synced 2025-07-30 21:07:27 +02:00
type traist update (first release)
[SVN r7673]
This commit is contained in:
@ -5,6 +5,7 @@
|
|||||||
// in all copies. This software is provided "as is" without express or implied
|
// in all copies. This software is provided "as is" without express or implied
|
||||||
// warranty, and with no claim as to its suitability for any purpose.
|
// warranty, and with no claim as to its suitability for any purpose.
|
||||||
|
|
||||||
|
// standalone test program for <boost/call_traits.hpp>
|
||||||
|
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
@ -5,6 +5,8 @@
|
|||||||
// in all copies. This software is provided "as is" without express or implied
|
// in all copies. This software is provided "as is" without express or implied
|
||||||
// warranty, and with no claim as to its suitability for any purpose.
|
// warranty, and with no claim as to its suitability for any purpose.
|
||||||
|
|
||||||
|
// standalone test program for <boost/compressed_pair.hpp>
|
||||||
|
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <typeinfo>
|
#include <typeinfo>
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
|
@ -6,6 +6,9 @@
|
|||||||
|
|
||||||
// See http://www.boost.org for most recent version including documentation.
|
// See http://www.boost.org for most recent version including documentation.
|
||||||
|
|
||||||
|
// call_traits: defines typedefs for function usage
|
||||||
|
// (see libs/utility/call_traits.htm)
|
||||||
|
|
||||||
/* Release notes:
|
/* Release notes:
|
||||||
23rd July 2000:
|
23rd July 2000:
|
||||||
Fixed array specialization. (JM)
|
Fixed array specialization. (JM)
|
||||||
|
@ -6,6 +6,8 @@
|
|||||||
|
|
||||||
// See http://www.boost.org for most recent version including documentation.
|
// See http://www.boost.org for most recent version including documentation.
|
||||||
|
|
||||||
|
// compressed_pair: pair that "compresses" empty members
|
||||||
|
// (see libs/utility/compressed_pair.htm)
|
||||||
//
|
//
|
||||||
// JM changes 25 Jan 2000:
|
// JM changes 25 Jan 2000:
|
||||||
// Removed default arguments from compressed_pair_switch to get
|
// Removed default arguments from compressed_pair_switch to get
|
||||||
|
@ -7,6 +7,7 @@
|
|||||||
// See http://www.boost.org for most recent version including documentation.
|
// See http://www.boost.org for most recent version including documentation.
|
||||||
//
|
//
|
||||||
// Crippled version for crippled compilers:
|
// Crippled version for crippled compilers:
|
||||||
|
// see libs/utility/call_traits.htm
|
||||||
//
|
//
|
||||||
#ifndef BOOST_OB_CALL_TRAITS_HPP
|
#ifndef BOOST_OB_CALL_TRAITS_HPP
|
||||||
#define BOOST_OB_CALL_TRAITS_HPP
|
#define BOOST_OB_CALL_TRAITS_HPP
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
// warranty, and with no claim as to its suitability for any purpose.
|
// warranty, and with no claim as to its suitability for any purpose.
|
||||||
|
|
||||||
// See http://www.boost.org for most recent version including documentation.
|
// See http://www.boost.org for most recent version including documentation.
|
||||||
|
// see libs/utility/compressed_pair.hpp
|
||||||
//
|
//
|
||||||
/* Release notes:
|
/* Release notes:
|
||||||
23rd July 2000:
|
23rd July 2000:
|
||||||
|
@ -141,7 +141,10 @@ is always defined as a compile time constant).</p>
|
|||||||
<td width="37%"><div align="center"><center><pre>alignment_of<T>::value</pre>
|
<td width="37%"><div align="center"><center><pre>alignment_of<T>::value</pre>
|
||||||
</center></div></td>
|
</center></div></td>
|
||||||
<td width="36%"><p align="center">An integral value
|
<td width="36%"><p align="center">An integral value
|
||||||
representing the minimum alignment requirements of type T.</p>
|
representing the minimum alignment requirements of type T
|
||||||
|
(strictly speaking defines a multiple of the type's
|
||||||
|
alignment requirement; for all compilers tested so far
|
||||||
|
however it does return the actual alignment).</p>
|
||||||
</td>
|
</td>
|
||||||
<td width="27%"> </td>
|
<td width="27%"> </td>
|
||||||
</tr>
|
</tr>
|
||||||
@ -454,9 +457,10 @@ will also be true.</p>
|
|||||||
or class. If the compiler implements the "zero sized
|
or class. If the compiler implements the "zero sized
|
||||||
empty base classes" optimisation, then is_empty will
|
empty base classes" optimisation, then is_empty will
|
||||||
correctly guess whether T is empty. Relies upon is_class
|
correctly guess whether T is empty. Relies upon is_class
|
||||||
to determine whether T is a class type - as a result will
|
to determine whether T is a class type. Screens out enum
|
||||||
not compile when passed an enumerated type unless there
|
types by using is_convertible<T,int>, this means
|
||||||
is compiler support for is_enum.</td>
|
that empty classes that overload operator int(), will not
|
||||||
|
be classified as empty.</td>
|
||||||
<td valign="top" width="33%"><p align="center">PCD</p>
|
<td valign="top" width="33%"><p align="center">PCD</p>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
@ -4,6 +4,8 @@
|
|||||||
// in all copies. This software is provided "as is" without express or implied
|
// in all copies. This software is provided "as is" without express or implied
|
||||||
// warranty, and with no claim as to its suitability for any purpose.
|
// warranty, and with no claim as to its suitability for any purpose.
|
||||||
|
|
||||||
|
// standalone test program for <boost/type_traits.hpp>
|
||||||
|
|
||||||
/* Release notes:
|
/* Release notes:
|
||||||
31st July 2000:
|
31st July 2000:
|
||||||
Added extra tests for is_empty, is_convertible, alignment_of.
|
Added extra tests for is_empty, is_convertible, alignment_of.
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
// in all copies. This software is provided "as is" without express or implied
|
// in all copies. This software is provided "as is" without express or implied
|
||||||
// warranty, and with no claim as to its suitability for any purpose.
|
// warranty, and with no claim as to its suitability for any purpose.
|
||||||
|
|
||||||
|
// common test code for type_traits_test.cpp/call_traits_test.cpp/compressed_pair_test.cpp
|
||||||
|
|
||||||
|
|
||||||
#ifndef BOOST_TYPE_TRAITS_TEST_HPP
|
#ifndef BOOST_TYPE_TRAITS_TEST_HPP
|
||||||
|
Reference in New Issue
Block a user