Fix "reference to 'thread' is ambiguous"
authorHans Fugal <fugalh@fb.com>
Tue, 21 Jul 2015 00:46:42 +0000 (17:46 -0700)
committerfacebook-github-bot-4 <folly-bot@fb.com>
Tue, 21 Jul 2015 23:52:44 +0000 (16:52 -0700)
Summary: This fixes github issue https://github.com/facebook/folly/issues/243

I don't understand why this is broken on osx, but the solution is to just `#include <thread>` in the header instead of trying to forward declare `std::thread`.

Reviewed By: @yfeldblum

Differential Revision: D2255026

folly/io/async/ScopedEventBaseThread.h

index 60d62d79b28e851a444907eb3c3d0eac764c286e..fa35f35fbe45c72e34ce535eda08522cbd235c5d 100644 (file)
 #pragma once
 
 #include <memory>
+#include <thread>
 #include <folly/io/async/EventBase.h>
 
-namespace std {
-class thread;
-}
-
 namespace folly {
 
 /**