Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r63879 - in sandbox/SOC/2010/bit_masks/boost/integer: . detail/bft/msvc_fixes/msvc9
From: bbartmanboost_at_[hidden]
Date: 2010-07-11 11:52:13


Author: bbartman
Date: 2010-07-11 11:52:13 EDT (Sun, 11 Jul 2010)
New Revision: 63879
URL: http://svn.boost.org/trac/boost/changeset/63879

Log:
attempting to suppress c4307 warning for right_shift so that my code will work correctly
Text files modified:
   sandbox/SOC/2010/bit_masks/boost/integer/detail/bft/msvc_fixes/msvc9/msvc_make_bitfield_tuple_fix.hpp | 94 ----------------------------------------
   sandbox/SOC/2010/bit_masks/boost/integer/high_bits_mask.hpp | 10 ++-
   2 files changed, 7 insertions(+), 97 deletions(-)

Modified: sandbox/SOC/2010/bit_masks/boost/integer/detail/bft/msvc_fixes/msvc9/msvc_make_bitfield_tuple_fix.hpp
==============================================================================
--- sandbox/SOC/2010/bit_masks/boost/integer/detail/bft/msvc_fixes/msvc9/msvc_make_bitfield_tuple_fix.hpp (original)
+++ sandbox/SOC/2010/bit_masks/boost/integer/detail/bft/msvc_fixes/msvc9/msvc_make_bitfield_tuple_fix.hpp 2010-07-11 11:52:13 EDT (Sun, 11 Jul 2010)
@@ -8,35 +8,6 @@
 
 
 namespace boost { namespace detail { namespace msvc_fixes {
-/** Used for fixing an inadequacy in MSVC9 which causes my make_bitfield_tuple
- * function template parameters not to be instantiated unless they are
- * typedef'ed peior to the function declaration.
- */
-#define BOOST_MAKE_BFT_HELPER_TYPEDEF(Z, N, DATA) \
- typedef typename get_create_parameter<\
- BitfieldTuple,N>::is_valid_index fixer_type ## N;
-
-/** Defines typedefs which prevent the MSVC9 compiler from failing where it
- * shouldn't
- * Creates the following pattern
- * typedef typename get_create_parameter<
- * BitfieldTuple,0>::is_valid_index fixer_type0;
- * ...
- * typedef typename get_create_parameter<
- * BitfieldTuple,N>::is_valid_index fixer_typeN;
- */
-#define BOOST_MAKE_BFT_COMPENSATE_FOR_MSVC() \
- BOOST_PP_REPEAT_FROM_TO( \
- 0,\
- BOOST_BFT_PARAM_COUNT, \
- BOOST_MAKE_BFT_HELPER_TYPEDEF,\
- BOOST_BFT_NOTHING )
-
-template <typename BitfieldTuple>
-struct msvc9_make_bft_fix {
- BOOST_MAKE_BFT_COMPENSATE_FOR_MSVC()
-};
-
 
 /** Used to help generate psudo variadic template paramerer apperance.
  * This make the typename T##N = mpl::void_ pattern.
@@ -99,71 +70,6 @@
 }}
 
 BOOST_MAKE_BFT_OVERLOADS();
-/*
-
-template <typename BitfieldTuple,BOOST_MAKE_BFT_TEMPLATE_PARAMETERS(2)>
-BitfieldTuple make_bitfield_tuple(BOOST_MAKE_BFT_FUNCTION_PARAMETERS(2)) {
- BitfieldTuple bft;
- BOOST_MAKE_BFT_GENERATE_ASSIGNMENT_CALLS(2);
- return bft;
-}
-
-template <typename BitfieldTuple,BOOST_MAKE_BFT_TEMPLATE_PARAMETERS(3)>
-BitfieldTuple make_bitfield_tuple(BOOST_MAKE_BFT_FUNCTION_PARAMETERS(3)) {
- BitfieldTuple bft;
- BOOST_MAKE_BFT_GENERATE_ASSIGNMENT_CALLS(3);
- return bft;
-}
-
-template <typename BitfieldTuple,BOOST_MAKE_BFT_TEMPLATE_PARAMETERS(4)>
-BitfieldTuple make_bitfield_tuple(BOOST_MAKE_BFT_FUNCTION_PARAMETERS(4)) {
- BitfieldTuple bft;
- BOOST_MAKE_BFT_GENERATE_ASSIGNMENT_CALLS(4)
- return bft;
-}
-
-template <typename BitfieldTuple,BOOST_MAKE_BFT_TEMPLATE_PARAMETERS(5)>
-BitfieldTuple make_bitfield_tuple(BOOST_MAKE_BFT_FUNCTION_PARAMETERS(5)) {
- BitfieldTuple bft;
- BOOST_MAKE_BFT_GENERATE_ASSIGNMENT_CALLS(5);
- return bft;
-}
-
-template <typename BitfieldTuple,BOOST_MAKE_BFT_TEMPLATE_PARAMETERS(6)>
-BitfieldTuple make_bitfield_tuple(BOOST_MAKE_BFT_FUNCTION_PARAMETERS(6)) {
- BitfieldTuple bft;
- BOOST_MAKE_BFT_GENERATE_ASSIGNMENT_CALLS(6);
- return bft;
-}
-
-template <typename BitfieldTuple,BOOST_MAKE_BFT_TEMPLATE_PARAMETERS(7)>
-BitfieldTuple make_bitfield_tuple( BOOST_MAKE_BFT_FUNCTION_PARAMETERS(7) ) {
- BitfieldTuple bft;
- BOOST_MAKE_BFT_GENERATE_ASSIGNMENT_CALLS(7);
- return bft;
-}
-
-template <typename BitfieldTuple,BOOST_MAKE_BFT_TEMPLATE_PARAMETERS(8)>
-BitfieldTuple make_bitfield_tuple(BOOST_MAKE_BFT_FUNCTION_PARAMETERS(8)) {
- BitfieldTuple bft;
- BOOST_MAKE_BFT_GENERATE_ASSIGNMENT_CALLS(8);
- return bft;
-}
-template <typename BitfieldTuple,BOOST_MAKE_BFT_TEMPLATE_PARAMETERS(9)>
-BitfieldTuple make_bitfield_tuple(BOOST_MAKE_BFT_FUNCTION_PARAMETERS(9)) {
- BitfieldTuple bft;
- BOOST_MAKE_BFT_GENERATE_ASSIGNMENT_CALLS(9);
- return bft;
-}
-
-template <typename BitfieldTuple,BOOST_MAKE_BFT_TEMPLATE_PARAMETERS(10)>
-BitfieldTuple make_bitfield_tuple(BOOST_MAKE_BFT_FUNCTION_PARAMETERS(10)) {
- BitfieldTuple bft;
- BOOST_MAKE_BFT_GENERATE_ASSIGNMENT_CALLS(10)
- return bft;
-}
-
-*/
 
 } // end boost::detail::msvc_fixes
 #endif

Modified: sandbox/SOC/2010/bit_masks/boost/integer/high_bits_mask.hpp
==============================================================================
--- sandbox/SOC/2010/bit_masks/boost/integer/high_bits_mask.hpp (original)
+++ sandbox/SOC/2010/bit_masks/boost/integer/high_bits_mask.hpp 2010-07-11 11:52:13 EDT (Sun, 11 Jul 2010)
@@ -16,20 +16,24 @@
 #include <boost/mpl/bitwise.hpp>
 #include <boost/mpl/size_t.hpp>
 
+
+
 namespace boost {
 
 #ifdef BOOST_MSVC
     
-
+#pragma warning( push )
+#pragma warning( disable : 4307 )
 namespace detail {
     template<typename T, unsigned int Width>
     struct evaluate_for_msvc_08 {
         typedef typename make_unsigned<T>::type unsigned_type;
- BOOST_STATIC_CONSTANT(T, val = (~(mpl::shift_right< mpl::size_t< ~(T(0)) >, mpl::size_t<Width> >::type::value) ));
+ BOOST_STATIC_CONSTANT(T, val = (~(mpl::shift_right< mpl::size_t< ~(T(0))
+ >, mpl::size_t<Width> >::type::value) ));
         typedef integral_constant<T, val> type;
     };
 }
-// integral_mask<T, ~ mpl::size_t<(mpl::shift_left< mpl::size_t< ~(T(0)) >, mpl::size_t<Width> >::type::value )>::value >
+#pragma warning( pop )
 
 #endif
 


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk