Commit 00de3cea authored by Jim Meyering's avatar Jim Meyering Committed by Facebook Github Bot

folly/test/SpinLockTest.cpp: avoid shadowing warnings

Summary: Fix warnings exposed by the upstream-proposed -Wshadow-compatible-local option.

Reviewed By: igorsugak

Differential Revision: D4041919

fbshipit-source-id: 52579a4b7477192ec7145f81216200f81b191183
parent 5898eb28
...@@ -45,8 +45,8 @@ void spinlockTestThread(LockedVal<LOCK>* v) { ...@@ -45,8 +45,8 @@ void spinlockTestThread(LockedVal<LOCK>* v) {
SpinLockGuardImpl<LOCK> g(v->lock); SpinLockGuardImpl<LOCK> g(v->lock);
int first = v->ar[0]; int first = v->ar[0];
for (size_t i = 1; i < sizeof v->ar / sizeof i; ++i) { for (size_t j = 1; j < sizeof v->ar / sizeof j; ++j) {
EXPECT_EQ(first, v->ar[i]); EXPECT_EQ(first, v->ar[j]);
} }
int byte = folly::Random::rand32(rng); int byte = folly::Random::rand32(rng);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment