Commit 85eb12f0 authored by Jim Meyering's avatar Jim Meyering Committed by Facebook Github Bot

folly/futures/test/WhileDoTest.cpp: avoid shadowing warnings

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

Reviewed By: nisardan

Differential Revision: D4041779

fbshipit-source-id: 375e485a30f01a0610d881fe8b3237cc062aedef
parent 30408a7a
......@@ -121,11 +121,11 @@ TEST(WhileDo, failure) {
TEST(WhileDo, interrupt) {
std::queue<std::shared_ptr<Promise<Unit>>> ps;
std::mutex ps_mutex;
int i = 0;
int interrupt = 0;
bool complete = false;
bool failure = false;
int i = 0;
auto pred = makePred(i);
auto thunk = makeThunk(ps, interrupt, ps_mutex);
auto f = folly::whileDo(pred, thunk)
......@@ -137,7 +137,7 @@ TEST(WhileDo, interrupt) {
FutureException eggs("eggs");
f.raise(eggs);
for (int i = 1; i <= 3; ++i) {
for (int j = 1; j <= 3; ++j) {
EXPECT_EQ(1, interrupt);
popAndFulfillPromise(ps, ps_mutex);
}
......
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