diff options
author | Vincent Ambo <tazjin@google.com> | 2020-05-19T14·54+0100 |
---|---|---|
committer | Vincent Ambo <tazjin@google.com> | 2020-05-19T14·55+0100 |
commit | c758de9d22506eb279c5abe61f621e5c8f61af95 (patch) | |
tree | 3b1703133f56f7e301f538014dc7e41713a2e980 /third_party/nix/src/libutil | |
parent | b508f5b91a1b0c7009dcafb23114fff8d6020765 (diff) |
style(3p/nix): Reformat all includes to match new style r/766
Diffstat (limited to 'third_party/nix/src/libutil')
20 files changed, 57 insertions, 25 deletions
diff --git a/third_party/nix/src/libutil/affinity.cc b/third_party/nix/src/libutil/affinity.cc index af3bc152f402..b6aedc77e54a 100644 --- a/third_party/nix/src/libutil/affinity.cc +++ b/third_party/nix/src/libutil/affinity.cc @@ -1,5 +1,7 @@ #include "affinity.hh" + #include <glog/logging.h> + #include "types.hh" #include "util.hh" diff --git a/third_party/nix/src/libutil/archive.cc b/third_party/nix/src/libutil/archive.cc index 8f98a3daf301..c6ee5fcb2a93 100644 --- a/third_party/nix/src/libutil/archive.cc +++ b/third_party/nix/src/libutil/archive.cc @@ -1,14 +1,17 @@ #include "archive.hh" + +#include <algorithm> +#include <cerrno> +#include <map> +#include <vector> + #include <dirent.h> #include <fcntl.h> #include <strings.h> // for strcasecmp #include <sys/stat.h> #include <sys/types.h> #include <unistd.h> -#include <algorithm> -#include <cerrno> -#include <map> -#include <vector> + #include "config.hh" #include "glog/logging.h" #include "util.hh" diff --git a/third_party/nix/src/libutil/args.cc b/third_party/nix/src/libutil/args.cc index b5bfb0e6a746..2199099e7cba 100644 --- a/third_party/nix/src/libutil/args.cc +++ b/third_party/nix/src/libutil/args.cc @@ -1,4 +1,5 @@ #include "args.hh" + #include "hash.hh" namespace nix { diff --git a/third_party/nix/src/libutil/args.hh b/third_party/nix/src/libutil/args.hh index dc41a6849b40..ba6582abe424 100644 --- a/third_party/nix/src/libutil/args.hh +++ b/third_party/nix/src/libutil/args.hh @@ -3,6 +3,7 @@ #include <iostream> #include <map> #include <memory> + #include "util.hh" namespace nix { diff --git a/third_party/nix/src/libutil/compression.cc b/third_party/nix/src/libutil/compression.cc index 1f284b097054..b025e33683c8 100644 --- a/third_party/nix/src/libutil/compression.cc +++ b/third_party/nix/src/libutil/compression.cc @@ -1,11 +1,14 @@ #include "compression.hh" + +#include <cstdio> +#include <cstring> +#include <iostream> + #include <brotli/decode.h> #include <brotli/encode.h> #include <bzlib.h> #include <lzma.h> -#include <cstdio> -#include <cstring> -#include <iostream> + #include "finally.hh" #include "glog/logging.h" #include "util.hh" diff --git a/third_party/nix/src/libutil/compression.hh b/third_party/nix/src/libutil/compression.hh index 405863f3be02..80b651e107d4 100644 --- a/third_party/nix/src/libutil/compression.hh +++ b/third_party/nix/src/libutil/compression.hh @@ -1,6 +1,7 @@ #pragma once #include <string> + #include "ref.hh" #include "serialise.hh" #include "types.hh" diff --git a/third_party/nix/src/libutil/config.cc b/third_party/nix/src/libutil/config.cc index 93550fafa3d6..83dbf8b6e54f 100644 --- a/third_party/nix/src/libutil/config.cc +++ b/third_party/nix/src/libutil/config.cc @@ -1,6 +1,8 @@ #define GOOGLE_STRIP_LOG 0 #include "config.hh" + #include <glog/logging.h> + #include "args.hh" #include "json.hh" // #include <glog/log_severity.h> diff --git a/third_party/nix/src/libutil/config.hh b/third_party/nix/src/libutil/config.hh index 375fefa52b7c..9735569d1084 100644 --- a/third_party/nix/src/libutil/config.hh +++ b/third_party/nix/src/libutil/config.hh @@ -1,5 +1,6 @@ #include <map> #include <set> + #include "types.hh" #pragma once diff --git a/third_party/nix/src/libutil/hash.cc b/third_party/nix/src/libutil/hash.cc index 647822213278..18b3c89795e8 100644 --- a/third_party/nix/src/libutil/hash.cc +++ b/third_party/nix/src/libutil/hash.cc @@ -1,11 +1,14 @@ #include "hash.hh" + +#include <cstring> +#include <iostream> + #include <fcntl.h> #include <openssl/md5.h> #include <openssl/sha.h> #include <sys/stat.h> #include <sys/types.h> -#include <cstring> -#include <iostream> + #include "archive.hh" #include "istringstream_nocopy.hh" #include "util.hh" diff --git a/third_party/nix/src/libutil/json.cc b/third_party/nix/src/libutil/json.cc index 37cae1680155..3e5608c582fa 100644 --- a/third_party/nix/src/libutil/json.cc +++ b/third_party/nix/src/libutil/json.cc @@ -1,4 +1,5 @@ #include "json.hh" + #include <cstring> #include <iomanip> diff --git a/third_party/nix/src/libutil/monitor-fd.hh b/third_party/nix/src/libutil/monitor-fd.hh index faf79e6381d2..54e9de848a13 100644 --- a/third_party/nix/src/libutil/monitor-fd.hh +++ b/third_party/nix/src/libutil/monitor-fd.hh @@ -1,12 +1,13 @@ #pragma once +#include <atomic> +#include <cstdlib> +#include <thread> + #include <poll.h> #include <signal.h> #include <sys/types.h> #include <unistd.h> -#include <atomic> -#include <cstdlib> -#include <thread> namespace nix { diff --git a/third_party/nix/src/libutil/pool.hh b/third_party/nix/src/libutil/pool.hh index 592bd50897cc..e25d82d8ec11 100644 --- a/third_party/nix/src/libutil/pool.hh +++ b/third_party/nix/src/libutil/pool.hh @@ -5,6 +5,7 @@ #include <limits> #include <list> #include <memory> + #include "ref.hh" #include "sync.hh" diff --git a/third_party/nix/src/libutil/serialise.cc b/third_party/nix/src/libutil/serialise.cc index 1014ef8f70c3..187642df66fc 100644 --- a/third_party/nix/src/libutil/serialise.cc +++ b/third_party/nix/src/libutil/serialise.cc @@ -1,8 +1,10 @@ #include "serialise.hh" + #include <boost/coroutine2/coroutine.hpp> #include <cerrno> #include <cstring> #include <memory> + #include "glog/logging.h" #include "util.hh" diff --git a/third_party/nix/src/libutil/serialise.hh b/third_party/nix/src/libutil/serialise.hh index 2ab4bdff6f46..d8c8b181f411 100644 --- a/third_party/nix/src/libutil/serialise.hh +++ b/third_party/nix/src/libutil/serialise.hh @@ -1,6 +1,7 @@ #pragma once #include <memory> + #include "types.hh" #include "util.hh" diff --git a/third_party/nix/src/libutil/thread-pool.cc b/third_party/nix/src/libutil/thread-pool.cc index 3f50b6aaa2e6..ee727aacd02a 100644 --- a/third_party/nix/src/libutil/thread-pool.cc +++ b/third_party/nix/src/libutil/thread-pool.cc @@ -1,4 +1,5 @@ #include "thread-pool.hh" + #include "affinity.hh" #include "glog/logging.h" diff --git a/third_party/nix/src/libutil/thread-pool.hh b/third_party/nix/src/libutil/thread-pool.hh index 18fd208b1bb4..d709c9dbc855 100644 --- a/third_party/nix/src/libutil/thread-pool.hh +++ b/third_party/nix/src/libutil/thread-pool.hh @@ -5,6 +5,7 @@ #include <map> #include <queue> #include <thread> + #include "sync.hh" #include "util.hh" diff --git a/third_party/nix/src/libutil/types.hh b/third_party/nix/src/libutil/types.hh index 25e9d23017cf..ac1b802ce0f1 100644 --- a/third_party/nix/src/libutil/types.hh +++ b/third_party/nix/src/libutil/types.hh @@ -6,6 +6,7 @@ #include <memory> #include <set> #include <string> + #include "ref.hh" /* Before 4.7, gcc's std::exception uses empty throw() specifiers for diff --git a/third_party/nix/src/libutil/util.cc b/third_party/nix/src/libutil/util.cc index 21c14b0cf5d7..941680b70a70 100644 --- a/third_party/nix/src/libutil/util.cc +++ b/third_party/nix/src/libutil/util.cc @@ -1,12 +1,5 @@ #include "util.hh" -#include <fcntl.h> -#include <grp.h> -#include <limits.h> -#include <pwd.h> -#include <sys/ioctl.h> -#include <sys/types.h> -#include <sys/wait.h> -#include <unistd.h> + #include <cctype> #include <cerrno> #include <cstdio> @@ -16,6 +9,16 @@ #include <iostream> #include <sstream> #include <thread> + +#include <fcntl.h> +#include <grp.h> +#include <limits.h> +#include <pwd.h> +#include <sys/ioctl.h> +#include <sys/types.h> +#include <sys/wait.h> +#include <unistd.h> + #include "affinity.hh" #include "finally.hh" #include "glog/logging.h" diff --git a/third_party/nix/src/libutil/util.hh b/third_party/nix/src/libutil/util.hh index 25e647325c83..3ebe18f54837 100644 --- a/third_party/nix/src/libutil/util.hh +++ b/third_party/nix/src/libutil/util.hh @@ -1,10 +1,5 @@ #pragma once -#include <dirent.h> -#include <signal.h> -#include <sys/stat.h> -#include <sys/types.h> -#include <unistd.h> #include <cstdio> #include <functional> #include <future> @@ -12,6 +7,13 @@ #include <map> #include <optional> #include <sstream> + +#include <dirent.h> +#include <signal.h> +#include <sys/stat.h> +#include <sys/types.h> +#include <unistd.h> + #include "types.hh" #ifndef HAVE_STRUCT_DIRENT_D_TYPE diff --git a/third_party/nix/src/libutil/xml-writer.cc b/third_party/nix/src/libutil/xml-writer.cc index cabf7812128e..77e63395f224 100644 --- a/third_party/nix/src/libutil/xml-writer.cc +++ b/third_party/nix/src/libutil/xml-writer.cc @@ -1,4 +1,5 @@ #include "xml-writer.hh" + #include <assert.h> namespace nix { |