summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2021-10-16 12:37:54 +0100
committerDan Goodliffe <dan@randomdan.homeip.net>2021-10-16 13:01:31 +0100
commitd1d6dad0f3292918ed491423dd83ccba887a9aec (patch)
treef76136da063a0b06e9d317cceb23dd231bb4f5e4
parentUse C++17 nested namespaces in headers (diff)
downloadlibadhocutil-d1d6dad0f3292918ed491423dd83ccba887a9aec.tar.bz2
libadhocutil-d1d6dad0f3292918ed491423dd83ccba887a9aec.tar.xz
libadhocutil-d1d6dad0f3292918ed491423dd83ccba887a9aec.zip
Remove include mutex, client should include the header(s) it needs
-rw-r--r--libadhocutil/cache.impl.h1
-rw-r--r--libadhocutil/lockHelpers.h2
-rw-r--r--libadhocutil/resourcePool.impl.h1
-rw-r--r--libadhocutil/unittests/testCache.cpp1
4 files changed, 3 insertions, 2 deletions
diff --git a/libadhocutil/cache.impl.h b/libadhocutil/cache.impl.h
index 6b72e29..2f509f8 100644
--- a/libadhocutil/cache.impl.h
+++ b/libadhocutil/cache.impl.h
@@ -6,6 +6,7 @@
#include <boost/lambda/lambda.hpp>
#include <ctime>
#include <memory>
+#include <mutex> // IWYU pragma: keep
#include <variant>
// IWYU pragma: no_include <boost/multi_index/detail/unbounded.hpp>
diff --git a/libadhocutil/lockHelpers.h b/libadhocutil/lockHelpers.h
index 3b3bda8..d306f9c 100644
--- a/libadhocutil/lockHelpers.h
+++ b/libadhocutil/lockHelpers.h
@@ -1,8 +1,6 @@
#ifndef ADHOCUTIL_LOCKHELPERS_H
#define ADHOCUTIL_LOCKHELPERS_H
-#include <mutex>
-
#define LIBADHOC_LOCK_CONCAT2(a, b) a##b
#define LIBADHOC_LOCK_CONCAT(a, b) LIBADHOC_LOCK_CONCAT2(a, b)
#define LIBADHOC_LOCK_WITHLINE(a) LIBADHOC_LOCK_CONCAT(a, __LINE__)
diff --git a/libadhocutil/resourcePool.impl.h b/libadhocutil/resourcePool.impl.h
index 5e89709..e1791be 100644
--- a/libadhocutil/resourcePool.impl.h
+++ b/libadhocutil/resourcePool.impl.h
@@ -13,6 +13,7 @@
#include <cstddef>
#include <exception>
#include <memory>
+#include <mutex> // IWYU pragma: keep
#include <thread>
#include <typeinfo>
diff --git a/libadhocutil/unittests/testCache.cpp b/libadhocutil/unittests/testCache.cpp
index 0cdd0ea..9144a51 100644
--- a/libadhocutil/unittests/testCache.cpp
+++ b/libadhocutil/unittests/testCache.cpp
@@ -4,6 +4,7 @@
#include "cache.impl.h"
#include <ctime>
#include <memory>
+#include <mutex> // IWYU pragma: keep
#include <ostream>
#include <string>
#include <unistd.h>