欢迎来到虫虫下载站 | 资源下载 资源专辑 关于我们
虫虫下载站

typeof.hpp

Boost provides free peer-reviewed portable C++ source libraries. We emphasize libraries that work
HPP
字号:
// 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

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -