From: <ric...@us...> - 2011-10-17 19:57:05
|
Revision: 1151 http://loki-lib.svn.sourceforge.net/loki-lib/?rev=1151&view=rev Author: rich_sposato Date: 2011-10-17 19:56:59 +0000 (Mon, 17 Oct 2011) Log Message: ----------- Added parantheses to remove compiler warning. Modified Paths: -------------- trunk/include/loki/SafeBits.h Modified: trunk/include/loki/SafeBits.h =================================================================== --- trunk/include/loki/SafeBits.h 2011-10-17 19:55:23 UTC (rev 1150) +++ trunk/include/loki/SafeBits.h 2011-10-17 19:56:59 UTC (rev 1151) @@ -177,8 +177,8 @@ #ifndef LOKI_BIT_FIELD_NONTEMPLATE_INIT template < unsigned int i > static SafeBitConst make_bit_const() { - LOKI_STATIC_CHECK( i <= ( 8 * sizeof(word_t) ), Index_is_beyond_size_of_data ); - LOKI_STATIC_CHECK( sizeof(SafeBitConst) == sizeof(word_t), Object_size_does_not_match_data_size ); + LOKI_STATIC_CHECK( ( i <= ( 8 * sizeof(word_t) ) ), Index_is_beyond_size_of_data ); + LOKI_STATIC_CHECK( ( sizeof(SafeBitConst) == sizeof(word_t) ), Object_size_does_not_match_data_size ); // Why check for ( i > 0 ) again inside the shift if the shift // can never be evaluated for i == 0? Some compilers see shift by ( i - 1 ) // and complain that for i == 0 the number is invalid, without This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |