From 8c854bd336b45db17b48c2101fb2846f84726cdc Mon Sep 17 00:00:00 2001 From: David Robillard Date: Mon, 14 Dec 2020 22:14:40 +0100 Subject: Clean up includes in core and server --- include/ingen/AtomForge.hpp | 8 ++++++-- include/ingen/Clock.hpp | 1 - include/ingen/DataAccess.hpp | 1 - include/ingen/FilePath.hpp | 2 +- include/ingen/InstanceAccess.hpp | 1 - include/ingen/Log.hpp | 2 +- include/ingen/Message.hpp | 1 + include/ingen/Module.hpp | 1 - include/ingen/Node.hpp | 2 +- include/ingen/Parser.hpp | 6 +++--- include/ingen/Properties.hpp | 1 + include/ingen/QueuedInterface.hpp | 3 +++ include/ingen/Tee.hpp | 2 +- include/ingen/URI.hpp | 4 ++-- include/ingen/World.hpp | 1 + include/ingen/client/SocketClient.hpp | 8 ++++++++ include/ingen/filesystem.hpp | 8 +++++--- include/ingen/fmt.hpp | 2 +- include/ingen/memory.hpp | 1 + 19 files changed, 36 insertions(+), 19 deletions(-) (limited to 'include/ingen') diff --git a/include/ingen/AtomForge.hpp b/include/ingen/AtomForge.hpp index 372fd29d..bc44b698 100644 --- a/include/ingen/AtomForge.hpp +++ b/include/ingen/AtomForge.hpp @@ -21,6 +21,8 @@ #include "lv2/atom/atom.h" #include "lv2/atom/forge.h" #include "lv2/atom/util.h" +#include "lv2/urid/urid.h" +#include "sord/sord.h" #include "sord/sordmm.hpp" #include "sratom/sratom.h" @@ -81,8 +83,10 @@ private: // Update size and reallocate if necessary if (lv2_atom_pad_size(_size + len) > _capacity) { _capacity = lv2_atom_pad_size(_size + len); - _buf = AtomPtr{ - static_cast(realloc(_buf.release(), _capacity))}; + + _buf = AtomPtr{static_cast( + realloc(_buf.release(), _capacity)), + FreeDeleter{}}; } // Append new data diff --git a/include/ingen/Clock.hpp b/include/ingen/Clock.hpp index 622dd4bf..deea0495 100644 --- a/include/ingen/Clock.hpp +++ b/include/ingen/Clock.hpp @@ -22,7 +22,6 @@ # include #else # include -# include #endif #include diff --git a/include/ingen/DataAccess.hpp b/include/ingen/DataAccess.hpp index 1763c54f..3ea70eff 100644 --- a/include/ingen/DataAccess.hpp +++ b/include/ingen/DataAccess.hpp @@ -27,7 +27,6 @@ #include #include -#include namespace ingen { diff --git a/include/ingen/FilePath.hpp b/include/ingen/FilePath.hpp index c82b738d..3d077266 100644 --- a/include/ingen/FilePath.hpp +++ b/include/ingen/FilePath.hpp @@ -19,7 +19,7 @@ #include "ingen/ingen.h" -#include +#include // IWYU pragma: export #include #include diff --git a/include/ingen/InstanceAccess.hpp b/include/ingen/InstanceAccess.hpp index ef8b3be0..e108d7d5 100644 --- a/include/ingen/InstanceAccess.hpp +++ b/include/ingen/InstanceAccess.hpp @@ -25,7 +25,6 @@ #include "lv2/core/lv2.h" #include -#include namespace ingen { diff --git a/include/ingen/Log.hpp b/include/ingen/Log.hpp index ae8e7539..5310c768 100644 --- a/include/ingen/Log.hpp +++ b/include/ingen/Log.hpp @@ -18,7 +18,7 @@ #define INGEN_LOG_HPP #include "ingen/LV2Features.hpp" -#include "ingen/fmt.hpp" +#include "ingen/fmt.hpp" // IWYU pragma: export #include "ingen/ingen.h" #include "lv2/core/lv2.h" #include "lv2/log/log.h" diff --git a/include/ingen/Message.hpp b/include/ingen/Message.hpp index 09444d4a..ad524390 100644 --- a/include/ingen/Message.hpp +++ b/include/ingen/Message.hpp @@ -21,6 +21,7 @@ #include "ingen/Properties.hpp" #include "ingen/Resource.hpp" #include "ingen/Status.hpp" +#include "ingen/URI.hpp" #include "raul/Path.hpp" #include diff --git a/include/ingen/Module.hpp b/include/ingen/Module.hpp index 88f4afcd..b540fe7d 100644 --- a/include/ingen/Module.hpp +++ b/include/ingen/Module.hpp @@ -17,7 +17,6 @@ #ifndef INGEN_MODULE_HPP #define INGEN_MODULE_HPP -#include "ingen/FilePath.hpp" #include "ingen/Library.hpp" #include "ingen/ingen.h" diff --git a/include/ingen/Node.hpp b/include/ingen/Node.hpp index 1a6b102a..39b33596 100644 --- a/include/ingen/Node.hpp +++ b/include/ingen/Node.hpp @@ -18,6 +18,7 @@ #define INGEN_NODE_HPP #include "ingen/Resource.hpp" +#include "ingen/URI.hpp" #include "ingen/ingen.h" #include "ingen/paths.hpp" #include "lilv/lilv.h" @@ -37,7 +38,6 @@ namespace ingen { class Arc; class FilePath; -class Store; class URIs; /** A node in the audio graph. diff --git a/include/ingen/Parser.hpp b/include/ingen/Parser.hpp index 45d087cd..03175318 100644 --- a/include/ingen/Parser.hpp +++ b/include/ingen/Parser.hpp @@ -18,11 +18,11 @@ #define INGEN_PARSER_HPP #include "ingen/FilePath.hpp" -#include "ingen/Properties.hpp" +#include "ingen/Properties.hpp" // IWYU pragma: keep #include "ingen/URI.hpp" #include "ingen/ingen.h" -#include "raul/Path.hpp" -#include "raul/Symbol.hpp" +#include "raul/Path.hpp" // IWYU pragma: keep +#include "raul/Symbol.hpp" // IWYU pragma: keep #include diff --git a/include/ingen/Properties.hpp b/include/ingen/Properties.hpp index cd81ba59..1a80d0af 100644 --- a/include/ingen/Properties.hpp +++ b/include/ingen/Properties.hpp @@ -18,6 +18,7 @@ #define INGEN_PROPERTIES_HPP #include "ingen/Atom.hpp" +#include "ingen/URI.hpp" #include "ingen/URIs.hpp" #include diff --git a/include/ingen/QueuedInterface.hpp b/include/ingen/QueuedInterface.hpp index e1818232..97fbb731 100644 --- a/include/ingen/QueuedInterface.hpp +++ b/include/ingen/QueuedInterface.hpp @@ -19,9 +19,12 @@ #include "ingen/Interface.hpp" #include "ingen/Message.hpp" +#include "ingen/URI.hpp" +#include #include #include +#include #include namespace ingen { diff --git a/include/ingen/Tee.hpp b/include/ingen/Tee.hpp index 46062493..1e6805cc 100644 --- a/include/ingen/Tee.hpp +++ b/include/ingen/Tee.hpp @@ -19,8 +19,8 @@ #include "ingen/Interface.hpp" #include "ingen/Message.hpp" +#include "ingen/URI.hpp" -#include #include #include #include diff --git a/include/ingen/URI.hpp b/include/ingen/URI.hpp index aec6587d..b8108224 100644 --- a/include/ingen/URI.hpp +++ b/include/ingen/URI.hpp @@ -22,8 +22,8 @@ #include "serd/serd.h" #include "sord/sordmm.hpp" -#include -#include +#include // IWYU pragma: export +#include // IWYU pragma: export #include #include diff --git a/include/ingen/World.hpp b/include/ingen/World.hpp index a138a95c..bff5f213 100644 --- a/include/ingen/World.hpp +++ b/include/ingen/World.hpp @@ -18,6 +18,7 @@ #define INGEN_WORLD_HPP #include "ingen/ingen.h" +#include "lilv/lilv.h" #include "lv2/log/log.h" #include "lv2/urid/urid.h" #include "raul/Noncopyable.hpp" diff --git a/include/ingen/client/SocketClient.hpp b/include/ingen/client/SocketClient.hpp index 9b10ac29..0e651250 100644 --- a/include/ingen/client/SocketClient.hpp +++ b/include/ingen/client/SocketClient.hpp @@ -20,12 +20,20 @@ #include "ingen/Log.hpp" #include "ingen/SocketReader.hpp" #include "ingen/SocketWriter.hpp" +#include "ingen/URI.hpp" +#include "ingen/World.hpp" #include "ingen/ingen.h" #include "raul/Socket.hpp" +#include +#include #include +#include namespace ingen { + +class Interface; + namespace client { /** The client side of an Ingen socket connection. */ diff --git a/include/ingen/filesystem.hpp b/include/ingen/filesystem.hpp index 44b9148e..abe7684e 100644 --- a/include/ingen/filesystem.hpp +++ b/include/ingen/filesystem.hpp @@ -27,14 +27,16 @@ # include # define F_OK 0 # define mkdir(path, flags) _mkdir(path) +#else +# include #endif +#include + +#include #include -#include #include #include -#include -#include #include /* A minimal subset of the std::filesystem API from C++17. */ diff --git a/include/ingen/fmt.hpp b/include/ingen/fmt.hpp index 3c792d3d..b2924d29 100644 --- a/include/ingen/fmt.hpp +++ b/include/ingen/fmt.hpp @@ -17,7 +17,7 @@ #ifndef INGEN_FMT_HPP #define INGEN_FMT_HPP -#include +#include // IWYU pragma: export #include #include diff --git a/include/ingen/memory.hpp b/include/ingen/memory.hpp index 8b5a5140..82e98bdf 100644 --- a/include/ingen/memory.hpp +++ b/include/ingen/memory.hpp @@ -19,6 +19,7 @@ #include #include +#include namespace ingen { -- cgit v1.2.1