Commit b1974960 authored by Mathieu Baudet's avatar Mathieu Baudet Committed by Facebook Github Bot

folly: remove unused includes

Summary:
Found with our include analysis tool.

I had to tweak `portability/Environment.h` to avoid a false positive breaking win32.

Reviewed By: yfeldblum, Orvid

Differential Revision: D4452463

fbshipit-source-id: e2e862e204892037ddde8815218e4deab1bfbb06
parent a857f83b
...@@ -17,11 +17,9 @@ ...@@ -17,11 +17,9 @@
#include <iostream> #include <iostream>
#include <stdexcept> #include <stdexcept>
#include <folly/File.h>
#include <folly/Format.h> #include <folly/Format.h>
#include <folly/MemoryMapping.h> #include <folly/MemoryMapping.h>
#include <folly/Range.h> #include <folly/Range.h>
#include <folly/ScopeGuard.h>
#include <folly/experimental/io/HugePages.h> #include <folly/experimental/io/HugePages.h>
#include <folly/portability/GFlags.h> #include <folly/portability/GFlags.h>
......
...@@ -27,15 +27,11 @@ ...@@ -27,15 +27,11 @@
#include <stdexcept> #include <stdexcept>
#include <system_error> #include <system_error>
#include <boost/noncopyable.hpp>
#include <boost/regex.hpp> #include <boost/regex.hpp>
#include <glog/logging.h>
#include <folly/Conv.h> #include <folly/Conv.h>
#include <folly/Format.h> #include <folly/Format.h>
#include <folly/Range.h> #include <folly/Range.h>
#include <folly/ScopeGuard.h>
#include <folly/String.h> #include <folly/String.h>
#include <folly/gen/Base.h> #include <folly/gen/Base.h>
......
...@@ -32,8 +32,6 @@ ...@@ -32,8 +32,6 @@
#include <glog/logging.h> #include <glog/logging.h>
#include <folly/Conv.h> #include <folly/Conv.h>
#include <folly/FileUtil.h>
#include <folly/Portability.h>
#include <folly/ScopeGuard.h> #include <folly/ScopeGuard.h>
#include <folly/experimental/symbolizer/ElfCache.h> #include <folly/experimental/symbolizer/ElfCache.h>
#include <folly/experimental/symbolizer/Symbolizer.h> #include <folly/experimental/symbolizer/Symbolizer.h>
......
...@@ -17,7 +17,6 @@ ...@@ -17,7 +17,6 @@
#include <iostream> #include <iostream>
#include <thread> #include <thread>
#include <folly/detail/Futex.h>
#include <folly/experimental/LockFreeRingBuffer.h> #include <folly/experimental/LockFreeRingBuffer.h>
#include <folly/test/DeterministicSchedule.h> #include <folly/test/DeterministicSchedule.h>
#include <folly/portability/GTest.h> #include <folly/portability/GTest.h>
......
...@@ -16,8 +16,6 @@ ...@@ -16,8 +16,6 @@
#include <folly/experimental/TestUtil.h> #include <folly/experimental/TestUtil.h>
#include <sys/types.h>
#include <system_error> #include <system_error>
#include <boost/algorithm/string.hpp> #include <boost/algorithm/string.hpp>
......
...@@ -18,8 +18,6 @@ ...@@ -18,8 +18,6 @@
#include <mutex> #include <mutex>
#include <queue> #include <queue>
#include <glog/logging.h>
#include <folly/futures/Future.h> #include <folly/futures/Future.h>
#include <folly/futures/Promise.h> #include <folly/futures/Promise.h>
#include <folly/portability/GTest.h> #include <folly/portability/GTest.h>
......
...@@ -17,10 +17,7 @@ ...@@ -17,10 +17,7 @@
#include <memory> #include <memory>
#include <mutex> #include <mutex>
#include <glog/logging.h>
#include <folly/futures/Future.h> #include <folly/futures/Future.h>
#include <folly/futures/Promise.h>
#include <folly/portability/GTest.h> #include <folly/portability/GTest.h>
using namespace folly; using namespace folly;
......
...@@ -18,8 +18,6 @@ ...@@ -18,8 +18,6 @@
#include <mutex> #include <mutex>
#include <queue> #include <queue>
#include <glog/logging.h>
#include <folly/futures/Future.h> #include <folly/futures/Future.h>
#include <folly/futures/Promise.h> #include <folly/futures/Promise.h>
#include <folly/portability/GTest.h> #include <folly/portability/GTest.h>
......
...@@ -19,7 +19,6 @@ ...@@ -19,7 +19,6 @@
#include <folly/Range.h> #include <folly/Range.h>
#include <folly/FBVector.h> #include <folly/FBVector.h>
#include <folly/experimental/TestUtil.h>
#include <folly/gen/Base.h> #include <folly/gen/Base.h>
#include <folly/gen/Combine.h> #include <folly/gen/Combine.h>
#include <folly/portability/GTest.h> #include <folly/portability/GTest.h>
......
...@@ -14,8 +14,6 @@ ...@@ -14,8 +14,6 @@
* limitations under the License. * limitations under the License.
*/ */
#include <glog/logging.h>
#include <iosfwd> #include <iosfwd>
#include <map> #include <map>
#include <vector> #include <vector>
......
...@@ -22,7 +22,6 @@ ...@@ -22,7 +22,6 @@
#include <glog/logging.h> #include <glog/logging.h>
#include <folly/FileUtil.h> #include <folly/FileUtil.h>
#include <folly/Malloc.h>
#include <folly/portability/Sockets.h> #include <folly/portability/Sockets.h>
namespace folly { namespace folly {
......
...@@ -19,7 +19,6 @@ ...@@ -19,7 +19,6 @@
#include <thread> #include <thread>
#include <folly/Function.h> #include <folly/Function.h>
#include <folly/Memory.h>
#include <folly/io/async/EventBaseManager.h> #include <folly/io/async/EventBaseManager.h>
using namespace std; using namespace std;
......
...@@ -13,7 +13,6 @@ ...@@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
#include <folly/Foreach.h>
#include <folly/io/Cursor.h> #include <folly/io/Cursor.h>
#include <folly/io/async/AsyncSSLSocket.h> #include <folly/io/async/AsyncSSLSocket.h>
#include <folly/io/async/AsyncSocket.h> #include <folly/io/async/AsyncSocket.h>
......
...@@ -24,7 +24,6 @@ ...@@ -24,7 +24,6 @@
#include <boost/algorithm/string.hpp> #include <boost/algorithm/string.hpp>
#include <folly/Conv.h> #include <folly/Conv.h>
#include <folly/Portability.h>
#include <folly/Range.h> #include <folly/Range.h>
#include <folly/String.h> #include <folly/String.h>
#include <folly/Unicode.h> #include <folly/Unicode.h>
......
...@@ -21,8 +21,7 @@ ...@@ -21,8 +21,7 @@
extern "C" { extern "C" {
#ifndef _WIN32 #ifndef _WIN32
extern char** environ; extern char** environ;
#else #endif
int setenv(const char* name, const char* value, int overwrite); int setenv(const char* name, const char* value, int overwrite);
int unsetenv(const char* name); int unsetenv(const char* name);
#endif
} }
...@@ -21,7 +21,6 @@ ...@@ -21,7 +21,6 @@
#include <atomic> #include <atomic>
#include <memory> #include <memory>
#include <folly/Assume.h>
#include <folly/Benchmark.h> #include <folly/Benchmark.h>
#include <folly/Conv.h> #include <folly/Conv.h>
#include <folly/portability/GTest.h> #include <folly/portability/GTest.h>
......
...@@ -22,8 +22,6 @@ ...@@ -22,8 +22,6 @@
#include <cstdio> #include <cstdio>
#include <memory> #include <memory>
#include <glog/logging.h>
namespace folly { namespace test { namespace folly { namespace test {
#define EXPECT_SYSTEM_ERROR(statement, err, msg) \ #define EXPECT_SYSTEM_ERROR(statement, err, msg) \
......
...@@ -24,7 +24,6 @@ ...@@ -24,7 +24,6 @@
#include <fstream> #include <fstream>
#include <sstream> #include <sstream>
#include <boost/algorithm/string.hpp>
#include <boost/random.hpp> #include <boost/random.hpp>
#include <folly/Benchmark.h> #include <folly/Benchmark.h>
......
...@@ -18,7 +18,6 @@ ...@@ -18,7 +18,6 @@
#include <folly/Benchmark.h> #include <folly/Benchmark.h>
#include <folly/Foreach.h> #include <folly/Foreach.h>
#include <folly/Range.h>
#include <glog/logging.h> #include <glog/logging.h>
......
...@@ -26,7 +26,6 @@ ...@@ -26,7 +26,6 @@
#include <folly/Benchmark.h> #include <folly/Benchmark.h>
#include <folly/MPMCQueue.h> #include <folly/MPMCQueue.h>
#include <folly/RWSpinLock.h> #include <folly/RWSpinLock.h>
#include <folly/Random.h>
#include <folly/portability/GFlags.h> #include <folly/portability/GFlags.h>
#include <folly/portability/GTest.h> #include <folly/portability/GTest.h>
#include <folly/test/DeterministicSchedule.h> #include <folly/test/DeterministicSchedule.h>
......
...@@ -29,7 +29,6 @@ ...@@ -29,7 +29,6 @@
#include <folly/Range.h> #include <folly/Range.h>
#include <folly/Benchmark.h> #include <folly/Benchmark.h>
#include <folly/Portability.h>
#include <folly/portability/GTest.h> #include <folly/portability/GTest.h>
using namespace folly; using namespace folly;
......
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