Commit 59fe375d authored by Alfred Fuller's avatar Alfred Fuller Committed by Facebook GitHub Bot

Fix include order and grouping in folly - 7/13

Summary: All changes were automated

Reviewed By: Orvid

Differential Revision: D25507555

fbshipit-source-id: c0be9a04b8a5f502f4753ce6e163a78c428bfad6
parent 4cc7f892
......@@ -28,11 +28,11 @@
#include <folly/hash/SpookyHashV2.h>
#include <cstring>
#include <folly/CppAttributes.h>
#include <folly/Portability.h>
#include <cstring>
namespace folly {
namespace hash {
......
......@@ -23,6 +23,7 @@
#endif
#include <stdint.h>
#include <cstddef>
namespace folly {
......
......@@ -14,13 +14,12 @@
* limitations under the License.
*/
#include <folly/hash/detail/ChecksumDetail.h>
#include <array>
#include <utility>
#include <folly/Bits.h>
#include <folly/ConstexprMath.h>
#include <folly/hash/detail/ChecksumDetail.h>
namespace folly {
......
......@@ -31,14 +31,13 @@
#include <stdexcept>
#include <folly/hash/detail/ChecksumDetail.h>
#include <folly/CppAttributes.h>
#include <boost/preprocessor/arithmetic/add.hpp>
#include <boost/preprocessor/arithmetic/sub.hpp>
#include <boost/preprocessor/repetition/repeat_from_to.hpp>
#include <folly/CppAttributes.h>
#include <folly/hash/detail/ChecksumDetail.h>
namespace folly {
namespace detail {
......
......@@ -17,6 +17,7 @@
#include <folly/hash/Hash.h>
#include <stdint.h>
#include <deque>
#include <random>
#include <string>
......
......@@ -15,9 +15,10 @@
*/
#pragma once
#include <folly/CPortability.h>
#include <bitset>
#include <folly/CPortability.h>
namespace folly {
class InitOptions {
public:
......
......@@ -16,12 +16,12 @@
#include <folly/init/Phase.h>
#include <folly/Singleton.h>
#include <folly/portability/GTest.h>
#include <thread>
#include <glog/logging.h>
#include <thread>
#include <folly/Singleton.h>
#include <folly/portability/GTest.h>
/// Types
......
......@@ -16,7 +16,6 @@
#pragma once
#include <glog/logging.h>
#include <atomic>
#include <cassert>
#include <cinttypes>
......@@ -27,6 +26,8 @@
#include <memory>
#include <type_traits>
#include <glog/logging.h>
#include <folly/FBString.h>
#include <folly/FBVector.h>
#include <folly/Function.h>
......
......@@ -17,7 +17,6 @@
#include <folly/io/IOBufQueue.h>
#include <cstring>
#include <stdexcept>
using std::make_pair;
......
......@@ -16,12 +16,12 @@
#pragma once
#include <folly/ScopeGuard.h>
#include <folly/io/IOBuf.h>
#include <stdexcept>
#include <string>
#include <folly/ScopeGuard.h>
#include <folly/io/IOBuf.h>
namespace folly {
/**
......
......@@ -15,10 +15,11 @@
*/
#include <folly/io/SocketOptionMap.h>
#include <folly/net/NetworkSocket.h>
#include <errno.h>
#include <folly/net/NetworkSocket.h>
namespace folly {
const SocketOptionMap emptySocketOptionMap;
......
......@@ -16,11 +16,11 @@
#pragma once
#include <map>
#include <folly/net/NetworkSocket.h>
#include <folly/portability/Sockets.h>
#include <map>
namespace folly {
/**
......
......@@ -16,11 +16,9 @@
#include <folly/io/async/AsyncSSLSocket.h>
#include <folly/io/async/EventBase.h>
#include <folly/portability/Sockets.h>
#include <fcntl.h>
#include <sys/types.h>
#include <cerrno>
#include <chrono>
#include <memory>
......@@ -33,9 +31,11 @@
#include <folly/io/Cursor.h>
#include <folly/io/IOBuf.h>
#include <folly/io/SocketOptionMap.h>
#include <folly/io/async/EventBase.h>
#include <folly/io/async/ssl/BasicTransportCertificate.h>
#include <folly/lang/Bits.h>
#include <folly/portability/OpenSSL.h>
#include <folly/portability/Sockets.h>
#include <folly/ssl/SSLSession.h>
#include <folly/ssl/SSLSessionManager.h>
......
......@@ -20,6 +20,11 @@
#include <folly/io/async/AsyncServerSocket.h>
#include <sys/types.h>
#include <cerrno>
#include <cstring>
#include <folly/FileUtil.h>
#include <folly/Portability.h>
#include <folly/SocketAddress.h>
......@@ -31,10 +36,6 @@
#include <folly/portability/Sockets.h>
#include <folly/portability/Unistd.h>
#include <sys/types.h>
#include <cerrno>
#include <cstring>
namespace folly {
#ifndef TCP_SAVE_SYN
......
......@@ -16,6 +16,14 @@
#pragma once
#include <limits.h>
#include <stddef.h>
#include <chrono>
#include <exception>
#include <memory>
#include <vector>
#include <folly/SocketAddress.h>
#include <folly/String.h>
#include <folly/experimental/observer/Observer.h>
......@@ -30,13 +38,6 @@
#include <folly/net/NetworkSocket.h>
#include <folly/portability/Sockets.h>
#include <limits.h>
#include <stddef.h>
#include <chrono>
#include <exception>
#include <memory>
#include <vector>
// Due to the way kernel headers are included, this may or may not be defined.
// Number pulled from 3.10 kernel headers.
#ifndef SO_REUSEPORT
......
......@@ -16,9 +16,8 @@
#include <folly/io/async/AsyncSignalHandler.h>
#include <folly/io/async/EventBase.h>
#include <folly/Conv.h>
#include <folly/io/async/EventBase.h>
using std::make_pair;
using std::pair;
......
......@@ -16,9 +16,10 @@
#pragma once
#include <map>
#include <folly/io/async/EventBase.h>
#include <folly/portability/Event.h>
#include <map>
namespace folly {
......
......@@ -16,6 +16,15 @@
#include <folly/io/async/AsyncSocket.h>
#include <sys/types.h>
#include <cerrno>
#include <climits>
#include <sstream>
#include <thread>
#include <boost/preprocessor/control/if.hpp>
#include <folly/ExceptionWrapper.h>
#include <folly/Format.h>
#include <folly/Portability.h>
......@@ -30,13 +39,6 @@
#include <folly/portability/SysUio.h>
#include <folly/portability/Unistd.h>
#include <boost/preprocessor/control/if.hpp>
#include <sys/types.h>
#include <cerrno>
#include <climits>
#include <sstream>
#include <thread>
#if defined(__linux__)
#include <linux/sockios.h>
#include <sys/ioctl.h>
......
......@@ -16,6 +16,12 @@
#pragma once
#include <sys/types.h>
#include <chrono>
#include <map>
#include <memory>
#include <folly/Optional.h>
#include <folly/SocketAddress.h>
#include <folly/detail/SocketFastOpen.h>
......@@ -30,12 +36,6 @@
#include <folly/portability/Sockets.h>
#include <folly/small_vector.h>
#include <sys/types.h>
#include <chrono>
#include <map>
#include <memory>
namespace folly {
/**
......
......@@ -15,13 +15,15 @@
*/
#include <folly/io/async/AsyncTimeout.h>
#include <cassert>
#include <glog/logging.h>
#include <folly/io/async/EventBase.h>
#include <folly/io/async/EventUtil.h>
#include <folly/net/NetworkSocket.h>
#include <glog/logging.h>
#include <cassert>
namespace folly {
AsyncTimeout::AsyncTimeout(TimeoutManager* timeoutManager)
......
......@@ -16,15 +16,14 @@
#pragma once
#include <memory>
#include <utility>
#include <folly/io/async/EventBaseBackendBase.h>
#include <folly/io/async/Request.h>
#include <folly/io/async/TimeoutManager.h>
#include <folly/portability/Event.h>
#include <memory>
#include <utility>
namespace folly {
class EventBase;
......
......@@ -16,6 +16,10 @@
#include <folly/io/async/AsyncUDPSocket.h>
#include <cerrno>
#include <boost/preprocessor/control/if.hpp>
#include <folly/Likely.h>
#include <folly/Utility.h>
#include <folly/io/SocketOptionMap.h>
......@@ -25,9 +29,6 @@
#include <folly/portability/Unistd.h>
#include <folly/small_vector.h>
#include <boost/preprocessor/control/if.hpp>
#include <cerrno>
// Due to the way kernel headers are included, this may or may not be defined.
// Number pulled from 3.10 kernel headers.
#ifndef SO_REUSEPORT
......
......@@ -16,9 +16,8 @@
#pragma once
#include <folly/io/async/AtomicNotificationQueue.h>
#include <folly/FileUtil.h>
#include <folly/io/async/AtomicNotificationQueue.h>
#include <folly/system/Pid.h>
namespace folly {
......
......@@ -16,9 +16,10 @@
#pragma once
#include <type_traits>
#include <folly/io/async/Request.h>
#include <folly/lang/Align.h>
#include <type_traits>
namespace folly {
......
......@@ -17,7 +17,7 @@
#pragma once
#include <assert.h>
#include <folly/Portability.h>
#include <cstddef>
#include <cstdint>
#include <functional>
......@@ -25,6 +25,8 @@
#include <type_traits>
#include <utility>
#include <folly/Portability.h>
namespace folly {
/**
......
......@@ -16,9 +16,8 @@
#pragma once
#include <folly/io/async/EventBaseAtomicNotificationQueue.h>
#include <folly/FileUtil.h>
#include <folly/io/async/EventBaseAtomicNotificationQueue.h>
#include <folly/system/Pid.h>
namespace folly {
......
......@@ -17,7 +17,6 @@
#pragma once
#include <folly/io/async/AtomicNotificationQueue.h>
#include <folly/io/async/EventBase.h>
#include <folly/io/async/EventHandler.h>
#include <folly/portability/Fcntl.h>
......
......@@ -15,6 +15,7 @@
*/
#include <folly/io/async/EventBaseBackendBase.h>
#include <folly/io/async/EventBase.h>
#if defined(__linux__) && !FOLLY_MOBILE
......
......@@ -15,10 +15,12 @@
*/
#include <folly/io/async/EventBaseLocal.h>
#include <folly/MapUtil.h>
#include <atomic>
#include <thread>
#include <folly/MapUtil.h>
namespace folly {
namespace detail {
......
......@@ -16,13 +16,14 @@
#pragma once
#include <folly/Synchronized.h>
#include <folly/io/async/EventBase.h>
#include <memory>
#include <mutex>
#include <unordered_set>
#include <utility>
#include <folly/Synchronized.h>
#include <folly/io/async/EventBase.h>
namespace folly {
namespace detail {
......
......@@ -16,9 +16,10 @@
#pragma once
#include <memory>
#include <folly/Range.h>
#include <folly/io/async/EventBase.h>
#include <memory>
namespace folly {
......
......@@ -15,11 +15,12 @@
*/
#include <folly/io/async/EventHandler.h>
#include <folly/String.h>
#include <folly/io/async/EventBase.h>
#include <cassert>
#include <folly/String.h>
#include <folly/io/async/EventBase.h>
namespace folly {
EventHandler::EventHandler(EventBase* eventBase, NetworkSocket fd) {
......
......@@ -16,19 +16,19 @@
#pragma once
#include <folly/Optional.h>
#include <folly/io/async/AsyncTimeout.h>
#include <folly/io/async/DelayedDestruction.h>
#include <folly/io/async/HHWheelTimer-fwd.h>
#include <boost/intrusive/list.hpp>
#include <glog/logging.h>
#include <array>
#include <chrono>
#include <cstddef>
#include <memory>
#include <boost/intrusive/list.hpp>
#include <glog/logging.h>
#include <folly/Optional.h>
#include <folly/io/async/AsyncTimeout.h>
#include <folly/io/async/DelayedDestruction.h>
#include <folly/io/async/HHWheelTimer-fwd.h>
namespace folly {
namespace detail {
......
......@@ -25,6 +25,8 @@
#include <utility>
#include <boost/intrusive/slist.hpp>
#include <glog/logging.h>
#include <folly/Exception.h>
#include <folly/FileUtil.h>
#include <folly/Likely.h>
......@@ -39,8 +41,6 @@
#include <folly/portability/Unistd.h>
#include <folly/system/Pid.h>
#include <glog/logging.h>
#if defined(__linux__) && !defined(__ANDROID__)
#define FOLLY_HAVE_EVENTFD
#include <folly/io/async/EventFDWrapper.h>
......
......@@ -15,14 +15,14 @@
*/
#include <folly/io/async/Request.h>
#include <folly/experimental/SingleWriterFixedHashMap.h>
#include <folly/synchronization/Hazptr.h>
#include <folly/tracing/StaticTracepoint.h>
#include <glog/logging.h>
#include <folly/MapUtil.h>
#include <folly/SingletonThreadLocal.h>
#include <folly/experimental/SingleWriterFixedHashMap.h>
#include <folly/synchronization/Hazptr.h>
#include <folly/tracing/StaticTracepoint.h>
namespace folly {
......
......@@ -16,16 +16,16 @@
#pragma once
#include <folly/Synchronized.h>
#include <folly/container/F14Map.h>
#include <folly/synchronization/Hazptr.h>
#include <atomic>
#include <memory>
#include <mutex>
#include <string>
#include <utility>
#include <folly/Synchronized.h>
#include <folly/container/F14Map.h>
#include <folly/synchronization/Hazptr.h>
namespace folly {
/*
......
......@@ -15,9 +15,11 @@
*/
#include <folly/io/async/SSLOptions.h>
#include <folly/Format.h>
#include <glog/logging.h>
#include <folly/Format.h>
namespace folly {
namespace ssl {
......
......@@ -17,14 +17,13 @@
#include <folly/io/async/TimeoutManager.h>
#include <boost/intrusive/list.hpp>
#include <glog/logging.h>
#include <folly/Chrono.h>
#include <folly/Exception.h>
#include <folly/Memory.h>
#include <folly/io/async/AsyncTimeout.h>
#include <glog/logging.h>
namespace folly {
struct TimeoutManager::CobTimeouts {
......
......@@ -16,9 +16,10 @@
#pragma once
#include <folly/io/async/AsyncTransportCertificate.h>
#include <memory>
#include <folly/io/async/AsyncTransportCertificate.h>
namespace folly {
namespace ssl {
......
......@@ -16,10 +16,10 @@
#include <folly/io/async/ssl/OpenSSLUtils.h>
#include <glog/logging.h>
#include <unordered_map>
#include <glog/logging.h>
#include <folly/ScopeGuard.h>
#include <folly/portability/Sockets.h>
#include <folly/portability/Unistd.h>
......
......@@ -16,11 +16,12 @@
#pragma once
#include <folly/io/Cursor.h>
#include <folly/io/IOBuf.h>
#include <map>
#include <vector>
#include <folly/io/Cursor.h>
#include <folly/io/IOBuf.h>
namespace folly {
namespace ssl {
......
......@@ -15,6 +15,7 @@
*/
#include <folly/io/async/ssl/OpenSSLUtils.h>
#include <folly/String.h>
#include <folly/portability/GTest.h>
#include <folly/portability/OpenSSL.h>
......
......@@ -15,12 +15,13 @@
*/
#include <folly/io/async/AsyncPipe.h>
#include <fcntl.h>
#include <folly/Memory.h>
#include <folly/io/async/EventBase.h>
#include <folly/portability/GTest.h>
#include <fcntl.h>
using namespace testing;
namespace {
......
......@@ -16,6 +16,16 @@
#include <folly/io/async/test/AsyncSSLSocketTest.h>
#include <fcntl.h>
#include <signal.h>
#include <sys/types.h>
#include <fstream>
#include <iostream>
#include <list>
#include <set>
#include <thread>
#include <folly/SocketAddress.h>
#include <folly/String.h>
#include <folly/io/Cursor.h>
......@@ -24,6 +34,7 @@
#include <folly/io/async/EventBase.h>
#include <folly/io/async/EventBaseThread.h>
#include <folly/io/async/ScopedEventBaseThread.h>
#include <folly/io/async/test/BlockingSocket.h>
#include <folly/net/NetOps.h>
#include <folly/net/NetworkSocket.h>
#include <folly/portability/GMock.h>
......@@ -32,18 +43,6 @@
#include <folly/portability/Unistd.h>
#include <folly/ssl/Init.h>
#include <folly/io/async/test/BlockingSocket.h>
#include <fcntl.h>
#include <signal.h>
#include <sys/types.h>
#include <fstream>
#include <iostream>
#include <list>
#include <set>
#include <thread>
#ifdef __linux__
#include <dlfcn.h>
#endif
......
......@@ -16,7 +16,14 @@
#pragma once
#include <fcntl.h>
#include <signal.h>
#include <sys/types.h>
#include <condition_variable>
#include <iostream>
#include <list>
#include <memory>
#include <folly/ExceptionWrapper.h>
#include <folly/SocketAddress.h>
......@@ -38,13 +45,6 @@
#include <folly/portability/String.h>
#include <folly/portability/Unistd.h>
#include <fcntl.h>
#include <sys/types.h>
#include <condition_variable>
#include <iostream>
#include <list>
#include <memory>
namespace folly {
// The destructors of all callback classes assert that the state is
......
......@@ -14,14 +14,14 @@
* limitations under the License.
*/
#include <folly/io/async/test/AsyncSSLSocketTest.h>
#include <folly/io/async/AsyncSSLSocket.h>
#include <folly/futures/Promise.h>
#include <folly/init/Init.h>
#include <folly/io/async/AsyncSSLSocket.h>
#include <folly/io/async/EventBase.h>
#include <folly/io/async/SSLContext.h>
#include <folly/io/async/ScopedEventBaseThread.h>
#include <folly/io/async/test/AsyncSSLSocketTest.h>
#include <folly/portability/GTest.h>
#include <folly/portability/PThread.h>
#include <folly/ssl/Init.h>
......
......@@ -14,6 +14,9 @@
* limitations under the License.
*/
#include <string>
#include <vector>
#include <folly/io/Cursor.h>
#include <folly/io/async/AsyncSSLSocket.h>
#include <folly/io/async/AsyncSocket.h>
......@@ -21,9 +24,6 @@
#include <folly/portability/GMock.h>
#include <folly/portability/GTest.h>
#include <string>
#include <vector>
using namespace testing;
namespace folly {
......
......@@ -14,10 +14,11 @@
* limitations under the License.
*/
#include <folly/io/async/AsyncSocket.h>
#include <iostream>
#include <folly/io/async/AsyncServerSocket.h>
#include <folly/io/async/AsyncSocket.h>
#include <folly/io/async/EventBase.h>
#include <folly/portability/GTest.h>
......
......@@ -16,14 +16,14 @@
#pragma once
#include <memory>
#include <folly/io/async/AsyncSocket.h>
#include <folly/io/async/test/BlockingSocket.h>
#include <folly/net/NetOps.h>
#include <folly/net/NetworkSocket.h>
#include <folly/portability/Sockets.h>
#include <memory>
enum StateEnum { STATE_WAITING, STATE_SUCCEEDED, STATE_FAILED };
typedef std::function<void()> VoidCallback;
......
......@@ -16,16 +16,22 @@
#include <folly/io/async/test/AsyncSocketTest2.h>
#include <fcntl.h>
#include <sys/types.h>
#include <iostream>
#include <memory>
#include <thread>
#include <folly/ExceptionWrapper.h>
#include <folly/Random.h>
#include <folly/SocketAddress.h>
#include <folly/experimental/TestUtil.h>
#include <folly/io/IOBuf.h>
#include <folly/io/SocketOptionMap.h>
#include <folly/io/async/AsyncTimeout.h>
#include <folly/io/async/EventBase.h>
#include <folly/io/async/ScopedEventBaseThread.h>
#include <folly/experimental/TestUtil.h>
#include <folly/io/IOBuf.h>
#include <folly/io/async/test/AsyncSocketTest.h>
#include <folly/io/async/test/Util.h>
#include <folly/portability/GMock.h>
......@@ -35,12 +41,6 @@
#include <folly/synchronization/Baton.h>
#include <folly/test/SocketAddressTestHelper.h>
#include <fcntl.h>
#include <sys/types.h>
#include <iostream>
#include <memory>
#include <thread>
using std::min;
using std::string;
using std::unique_ptr;
......
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