Fix Build: folly/io/async/test/ScopedEventBasedThreadTest.cpp
authorYedidya Feldblum <yfeldblum@fb.com>
Tue, 14 Jul 2015 00:18:23 +0000 (17:18 -0700)
committerSara Golemon <sgolemon@fb.com>
Wed, 15 Jul 2015 20:25:10 +0000 (13:25 -0700)
Summary: [Folly] Fix Build: folly/io/async/test/ScopedEventBasedThreadTest.cpp

Failure with latest clang:

    folly/io/async/test/ScopedEventBaseThreadTest.cpp:72:8: error: explicitly moving variable of type 'folly::ScopedEventBaseThread' to itself [-Werror,-Wself-move]
      sebt = std::move(sebt);

Reviewed By: @markisaa

Differential Revision: D2238762

folly/io/async/test/ScopedEventBaseThreadTest.cpp

index ba94518ae92ccd4dd5a58d967c1d8ccdf813ba56..b6373070089baf24cf5268ec582cd3fcc8e20d25 100644 (file)
@@ -68,8 +68,8 @@ TEST_F(ScopedEventBaseThreadTest, move) {
 }
 
 TEST_F(ScopedEventBaseThreadTest, self_move) {
-  ScopedEventBaseThread sebt;
-  sebt = std::move(sebt);
+  ScopedEventBaseThread sebt0;
+  auto sebt = std::move(sebt0);
 
   EXPECT_NE(nullptr, sebt.getEventBase());