Ticket #13015: shadowed_members.patch
File shadowed_members.patch, 3.5 KB (added by , 5 years ago) |
---|
-
MAIN/Third_Party_Libraries/Boost/include/boost/random/shuffle_order.hpp
old new 200 200 } 201 201 202 202 /** Returns true if the two generators will produce identical sequences. */ 203 BOOST_RANDOM_DETAIL_EQUALITY_OPERATOR(shuffle_order_engine, x,y)204 { return x._rng == y._rng && x.y == y.y && std::equal(x.v, x.v+k,y.v); }203 BOOST_RANDOM_DETAIL_EQUALITY_OPERATOR(shuffle_order_engine, _x, _y) 204 { return _x._rng == _y._rng && _x.y == _y.y && std::equal(_x.v, _x.v+k, _y.v); } 205 205 /** Returns true if the two generators will produce different sequences. */ 206 206 BOOST_RANDOM_DETAIL_INEQUALITY_OPERATOR(shuffle_order_engine) 207 207 -
MAIN/Third_Party_Libraries/Boost/include/boost/random/subtract_with_carry.hpp
old new 244 244 * Returns true if the two generators will produce identical 245 245 * sequences of values. 246 246 */ 247 BOOST_RANDOM_DETAIL_EQUALITY_OPERATOR(subtract_with_carry_engine, x,y)247 BOOST_RANDOM_DETAIL_EQUALITY_OPERATOR(subtract_with_carry_engine, _x, _y) 248 248 { 249 249 for(unsigned int j = 0; j < r; ++j) 250 if( x.compute(j) !=y.compute(j))250 if(_x.compute(j) != _y.compute(j)) 251 251 return false; 252 252 return true; 253 253 } … … 268 268 269 269 friend struct detail::subtract_with_carry_discard; 270 270 271 IntType do_update(std::size_t current, std::size_t short_index, IntType carry)271 IntType do_update(std::size_t current, std::size_t short_index, IntType _carry) 272 272 { 273 273 IntType delta; 274 IntType temp = x[current] + carry;274 IntType temp = x[current] + _carry; 275 275 if (x[short_index] >= temp) { 276 276 // x(n) >= 0 277 277 delta = x[short_index] - temp; 278 carry = 0;278 _carry = 0; 279 279 } else { 280 280 // x(n) < 0 281 281 delta = modulus - temp + x[short_index]; 282 carry = 1;282 _carry = 1; 283 283 } 284 284 x[current] = delta; 285 return carry;285 return _carry; 286 286 } 287 287 /// \endcond 288 288 … … 478 478 } 479 479 480 480 /** Returns true if the two generators will produce identical sequences. */ 481 BOOST_RANDOM_DETAIL_EQUALITY_OPERATOR(subtract_with_carry_01_engine, x,y)481 BOOST_RANDOM_DETAIL_EQUALITY_OPERATOR(subtract_with_carry_01_engine, _x, _y) 482 482 { 483 483 for(unsigned int j = 0; j < r; ++j) 484 if( x.compute(j) !=y.compute(j))484 if(_x.compute(j) != _y.compute(j)) 485 485 return false; 486 486 return true; 487 487 } … … 498 498 499 499 friend struct detail::subtract_with_carry_discard; 500 500 501 RealType do_update(std::size_t current, std::size_t short_index, RealType carry)501 RealType do_update(std::size_t current, std::size_t short_index, RealType _carry) 502 502 { 503 RealType delta = x[short_index] - x[current] - carry;503 RealType delta = x[short_index] - x[current] - _carry; 504 504 if(delta < 0) { 505 505 delta += RealType(1); 506 carry = RealType(1)/_modulus;506 _carry = RealType(1)/_modulus; 507 507 } else { 508 carry = 0;508 _carry = 0; 509 509 } 510 510 x[current] = delta; 511 return carry;511 return _carry; 512 512 } 513 513 /// \endcond 514 514 std::size_t k;