Subject: [Boost-bugs] [Boost C++ Libraries] #9115: Warnings in mersenne twister and lagged fibonacci with -Wshadow on clang
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2013-09-14 12:44:40
#9115: Warnings in mersenne twister and lagged fibonacci with -Wshadow on clang
-------------------------------------+---------------------------
Reporter: mgaunard | Owner: no-maintainer
Type: Bugs | Status: new
Milestone: To Be Determined | Component: random
Version: Boost Development Trunk | Severity: Problem
Keywords: |
-------------------------------------+---------------------------
/home/nt2/dev/boost/trunk/boost/random/mersenne_twister.hpp:237:59:
warning: declaration shadows a field of 'mersenne_twister_engine<UIntType,
w, n, m, r, a, u, d, s, b, t, c, l, f>' [-Wshadow]
friend bool operator==(const mersenne_twister_engine& x,
^
/home/nt2/dev/boost/trunk/boost/random/mersenne_twister.hpp:376:14: note:
previous declaration is here
UIntType x[n];
^
/home/nt2/dev/boost/trunk/boost/random/mersenne_twister.hpp:247:59:
warning: declaration shadows a field of 'mersenne_twister_engine<UIntType,
w, n, m, r, a, u, d, s, b, t, c, l, f>' [-Wshadow]
friend bool operator!=(const mersenne_twister_engine& x,
^
/home/nt2/dev/boost/trunk/boost/random/mersenne_twister.hpp:376:14: note:
previous declaration is here
UIntType x[n];
^
In file included from
/home/nt2/dev/nt2/modules/core/random/src/rand/randstream.cpp:10:
In file included from
/home/nt2/dev/nt2/modules/core/random/include/nt2/core/utility/randstream.hpp:14:
/home/nt2/dev/boost/trunk/boost/random/lagged_fibonacci.hpp:146:26:
warning: declaration shadows a field of 'lagged_fibonacci_engine<UIntType,
w, p, q>' [-Wshadow]
for(unsigned int i = 0; i < f.long_lag; ++i)
^
/home/nt2/dev/boost/trunk/boost/random/lagged_fibonacci.hpp:180:18: note:
previous declaration is here
unsigned int i;
^
/home/nt2/dev/boost/trunk/boost/random/lagged_fibonacci.hpp:157:26:
warning: declaration shadows a field of 'lagged_fibonacci_engine<UIntType,
w, p, q>' [-Wshadow]
for(unsigned int i = 0; i < f.long_lag; ++i)
^
/home/nt2/dev/boost/trunk/boost/random/lagged_fibonacci.hpp:180:18: note:
previous declaration is here
unsigned int i;
^
/home/nt2/dev/boost/trunk/boost/random/lagged_fibonacci.hpp:166:68:
warning: declaration shadows a field of 'lagged_fibonacci_engine<UIntType,
w, p, q>' [-Wshadow]
BOOST_RANDOM_DETAIL_EQUALITY_OPERATOR(lagged_fibonacci_engine, x, y)
^
/home/nt2/dev/boost/trunk/boost/random/detail/operators.hpp:75:37: note:
expanded from macro 'BOOST_RANDOM_DETAIL_EQUALITY_OPERATOR'
friend bool operator==(const T& lhs, const T& rhs)
^
/home/nt2/dev/boost/trunk/boost/random/lagged_fibonacci.hpp:181:14: note:
previous declaration is here
UIntType x[long_lag];
^
/home/nt2/dev/boost/trunk/boost/random/lagged_fibonacci.hpp:357:26:
warning: declaration shadows a field of
'lagged_fibonacci_01_engine<RealType, w, p, q>' [-Wshadow]
for(unsigned int i = 0; i < f.long_lag; ++i)
^
/home/nt2/dev/boost/trunk/boost/random/lagged_fibonacci.hpp:399:18: note:
previous declaration is here
unsigned int i;
^
/home/nt2/dev/boost/trunk/boost/random/lagged_fibonacci.hpp:369:26:
warning: declaration shadows a field of
'lagged_fibonacci_01_engine<RealType, w, p, q>' [-Wshadow]
for(unsigned int i = 0; i < f.long_lag; ++i) {
^
/home/nt2/dev/boost/trunk/boost/random/lagged_fibonacci.hpp:399:18: note:
previous declaration is here
unsigned int i;
^
/home/nt2/dev/boost/trunk/boost/random/lagged_fibonacci.hpp:381:71:
warning: declaration shadows a field of
'lagged_fibonacci_01_engine<RealType, w, p, q>' [-Wshadow]
BOOST_RANDOM_DETAIL_EQUALITY_OPERATOR(lagged_fibonacci_01_engine, x,
y)
^
/home/nt2/dev/boost/trunk/boost/random/detail/operators.hpp:75:37: note:
expanded from macro 'BOOST_RANDOM_DETAIL_EQUALITY_OPERATOR'
friend bool operator==(const T& lhs, const T& rhs)
^
/home/nt2/dev/boost/trunk/boost/random/lagged_fibonacci.hpp:400:14: note:
previous declaration is here
RealType x[long_lag];
^
8 warnings generated.
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/9115> Boost C++ Libraries <http://www.boost.org/> Boost provides free peer-reviewed portable C++ source libraries.
This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:14 UTC