diff options
author | Remko Tronçon <git@el-tramo.be> | 2010-03-28 15:46:49 (GMT) |
---|---|---|
committer | Remko Tronçon <git@el-tramo.be> | 2010-03-28 15:46:49 (GMT) |
commit | f53a1ef582494458301b97bf6e546be52d7ff7e8 (patch) | |
tree | 7571b5cbcbd8a8f1dd1c966c9045b6cb69f0e295 /3rdParty/Boost/src/boost/type_traits/msvc/typeof.hpp | |
parent | 638345680d72ca6acaf123f2c8c1c391f696e371 (diff) | |
download | swift-f53a1ef582494458301b97bf6e546be52d7ff7e8.zip swift-f53a1ef582494458301b97bf6e546be52d7ff7e8.tar.bz2 |
Moving submodule contents back.
Diffstat (limited to '3rdParty/Boost/src/boost/type_traits/msvc/typeof.hpp')
-rw-r--r-- | 3rdParty/Boost/src/boost/type_traits/msvc/typeof.hpp | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/3rdParty/Boost/src/boost/type_traits/msvc/typeof.hpp b/3rdParty/Boost/src/boost/type_traits/msvc/typeof.hpp new file mode 100644 index 0000000..ebb0e80 --- /dev/null +++ b/3rdParty/Boost/src/boost/type_traits/msvc/typeof.hpp @@ -0,0 +1,50 @@ +// Copyright (C) 2004 Peder Holt +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (http://www.boost.org/LICENSE_1_0.txt) + +#ifndef BOOST_TYPETRAITS_MSVC_TYPEOF_HPP +#define BOOST_TYPETRAITS_MSVC_TYPEOF_HPP + +#include <boost/config.hpp> +#include <boost/detail/workaround.hpp> + +namespace boost { namespace detail { +# if BOOST_WORKAROUND(BOOST_MSVC,==1300) + template<typename ID> + struct msvc_extract_type + { + template<bool> + struct id2type_impl; + + typedef id2type_impl<true> id2type; + }; + + template<typename T, typename ID> + struct msvc_register_type : msvc_extract_type<ID> + { + template<> + struct id2type_impl<true> //VC7.0 specific bugfeature + { + typedef T type; + }; + }; +# else + template<typename ID> + struct msvc_extract_type + { + struct id2type; + }; + + template<typename T, typename ID> + struct msvc_register_type : msvc_extract_type<ID> + { + typedef msvc_extract_type<ID> base_type; + struct base_type::id2type // This uses nice VC6.5 and VC7.1 bugfeature + { + typedef T type; + }; + }; +# endif +}} + +#endif //BOOST_TYPETRAITS_MSVC_TYPEOF_IMPL_HPP |