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

folly/test/SingletonTest.cpp: avoid shadowing warnings

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

Reviewed By: elsteveogrande

Differential Revision: D4041798

fbshipit-source-id: 9fb6901e791176eb42c31f287655aea6be95a30b
parent 17957da0
...@@ -171,13 +171,11 @@ TEST(Singleton, NaughtyUsage) { ...@@ -171,13 +171,11 @@ TEST(Singleton, NaughtyUsage) {
SingletonNaughtyUsage2<Watchdog> watchdog_singleton; SingletonNaughtyUsage2<Watchdog> watchdog_singleton;
// double registration // double registration
EXPECT_DEATH([]() { SingletonNaughtyUsage2<Watchdog> watchdog_singleton; }(), EXPECT_DEATH([]() { SingletonNaughtyUsage2<Watchdog> w2; }(), "");
"");
vault2.destroyInstances(); vault2.destroyInstances();
// double registration after destroy // double registration after destroy
EXPECT_DEATH([]() { SingletonNaughtyUsage2<Watchdog> watchdog_singleton; }(), EXPECT_DEATH([]() { SingletonNaughtyUsage2<Watchdog> w3; }(), "");
"");
} }
struct SharedPtrUsageTag {}; struct SharedPtrUsageTag {};
......
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