diff options
author | David Robillard <d@drobilla.net> | 2022-12-13 01:23:28 -0500 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2022-12-14 18:04:27 -0500 |
commit | 5d6ab4915c3b93f534c45bb6f84bf3273221e87c (patch) | |
tree | cfa2693d677a8261d5d2ab0125b7369dc39a7f86 /src | |
parent | 513296b868df8a3c5a55290d3146cba017418926 (diff) | |
download | ingen-5d6ab4915c3b93f534c45bb6f84bf3273221e87c.tar.gz ingen-5d6ab4915c3b93f534c45bb6f84bf3273221e87c.tar.bz2 ingen-5d6ab4915c3b93f534c45bb6f84bf3273221e87c.zip |
Concatenate nested namespaces
Diffstat (limited to 'src')
111 files changed, 223 insertions, 477 deletions
diff --git a/src/client/BlockModel.cpp b/src/client/BlockModel.cpp index aa4ef663..7448ca6c 100644 --- a/src/client/BlockModel.cpp +++ b/src/client/BlockModel.cpp @@ -34,8 +34,7 @@ #include <string> #include <utility> -namespace ingen { -namespace client { +namespace ingen::client { BlockModel::BlockModel(URIs& uris, const std::shared_ptr<PluginModel>& plugin, @@ -292,5 +291,4 @@ BlockModel::set(const std::shared_ptr<ObjectModel>& model) ObjectModel::set(model); } -} // namespace client -} // namespace ingen +} // namespace ingen::client diff --git a/src/client/ClientStore.cpp b/src/client/ClientStore.cpp index 02f28324..c492d3e6 100644 --- a/src/client/ClientStore.cpp +++ b/src/client/ClientStore.cpp @@ -42,8 +42,7 @@ #include <utility> #include <variant> -namespace ingen { -namespace client { +namespace ingen::client { ClientStore::ClientStore(URIs& uris, Log& log, @@ -501,5 +500,4 @@ ClientStore::operator()(const DisconnectAll& msg) } } -} // namespace client -} // namespace ingen +} // namespace ingen::client diff --git a/src/client/GraphModel.cpp b/src/client/GraphModel.cpp index a8a40ec7..2a998fdf 100644 --- a/src/client/GraphModel.cpp +++ b/src/client/GraphModel.cpp @@ -30,8 +30,7 @@ #include <string> #include <utility> -namespace ingen { -namespace client { +namespace ingen::client { void GraphModel::add_child(const std::shared_ptr<ObjectModel>& c) @@ -181,5 +180,4 @@ GraphModel::polyphonic() const return poly.is_valid() && poly.get<int32_t>(); } -} // namespace client -} // namespace ingen +} // namespace ingen::client diff --git a/src/client/ObjectModel.cpp b/src/client/ObjectModel.cpp index 9db429c5..86ffa821 100644 --- a/src/client/ObjectModel.cpp +++ b/src/client/ObjectModel.cpp @@ -29,8 +29,7 @@ #include <string> #include <utility> -namespace ingen { -namespace client { +namespace ingen::client { ObjectModel::ObjectModel(URIs& uris, const raul::Path& path) : Node(uris, path) @@ -113,5 +112,4 @@ ObjectModel::set_parent(const std::shared_ptr<ObjectModel>& p) _parent = p; } -} // namespace client -} // namespace ingen +} // namespace ingen::client diff --git a/src/client/PluginModel.cpp b/src/client/PluginModel.cpp index 4e0391f2..4371132c 100644 --- a/src/client/PluginModel.cpp +++ b/src/client/PluginModel.cpp @@ -28,8 +28,7 @@ using std::string; -namespace ingen { -namespace client { +namespace ingen::client { LilvWorld* PluginModel::_lilv_world = nullptr; const LilvPlugins* PluginModel::_lilv_plugins = nullptr; @@ -359,5 +358,4 @@ PluginModel::set_lilv_world(LilvWorld* world) _lilv_plugins = lilv_world_get_all_plugins(_lilv_world); } -} // namespace client -} // namespace ingen +} // namespace ingen::client diff --git a/src/client/PluginUI.cpp b/src/client/PluginUI.cpp index 031caceb..f0c3834a 100644 --- a/src/client/PluginUI.cpp +++ b/src/client/PluginUI.cpp @@ -36,8 +36,7 @@ #include <string> #include <utility> -namespace ingen { -namespace client { +namespace ingen::client { SuilHost* PluginUI::ui_host = nullptr; @@ -344,5 +343,4 @@ PluginUI::is_resizable() const return !fs_matches && !nrs_matches; } -} // namespace client -} // namespace ingen +} // namespace ingen::client diff --git a/src/client/PortModel.cpp b/src/client/PortModel.cpp index 0d695a54..73f273c7 100644 --- a/src/client/PortModel.cpp +++ b/src/client/PortModel.cpp @@ -27,8 +27,7 @@ #include <memory> #include <utility> -namespace ingen { -namespace client { +namespace ingen::client { void PortModel::on_property(const URI& uri, const Atom& value) @@ -84,5 +83,4 @@ PortModel::set(const std::shared_ptr<ObjectModel>& model) } } -} // namespace client -} // namespace ingen +} // namespace ingen::client diff --git a/src/gui/App.cpp b/src/gui/App.cpp index 7ec6014e..23b77df5 100644 --- a/src/gui/App.cpp +++ b/src/gui/App.cpp @@ -74,8 +74,7 @@ #include <utility> #include <variant> -namespace ingen { -namespace gui { +namespace ingen::gui { Gtk::Main* App::_main = nullptr; @@ -502,5 +501,4 @@ App::sample_rate() const return _sample_rate; } -} // namespace gui -} // namespace ingen +} // namespace ingen::gui diff --git a/src/gui/BreadCrumbs.cpp b/src/gui/BreadCrumbs.cpp index 942b88f5..2033457d 100644 --- a/src/gui/BreadCrumbs.cpp +++ b/src/gui/BreadCrumbs.cpp @@ -29,8 +29,7 @@ #include <string> #include <variant> -namespace ingen { -namespace gui { +namespace ingen::gui { using std::string; @@ -227,5 +226,4 @@ BreadCrumbs::object_moved(const raul::Path& old_path, const raul::Path& new_path } } -} // namespace gui -} // namespace ingen +} // namespace ingen::gui diff --git a/src/gui/BreadCrumbs.hpp b/src/gui/BreadCrumbs.hpp index 9ed6f04a..e7fffc18 100644 --- a/src/gui/BreadCrumbs.hpp +++ b/src/gui/BreadCrumbs.hpp @@ -35,8 +35,7 @@ #include <memory> #include <string> -namespace ingen { -namespace gui { +namespace ingen::gui { class App; @@ -122,7 +121,6 @@ private: std::list<BreadCrumb*> _breadcrumbs; }; -} // namespace gui -} // namespace ingen +} // namespace ingen::gui #endif // INGEN_GUI_BREADCRUMBS_HPP diff --git a/src/gui/ConnectWindow.cpp b/src/gui/ConnectWindow.cpp index 4569acec..2fd3be8c 100644 --- a/src/gui/ConnectWindow.cpp +++ b/src/gui/ConnectWindow.cpp @@ -63,8 +63,7 @@ #include <utility> #include <variant> -namespace ingen { -namespace gui { +namespace ingen::gui { ConnectWindow::ConnectWindow(BaseObjectType* cobject, Glib::RefPtr<Gtk::Builder> xml) @@ -571,5 +570,4 @@ ConnectWindow::quit() Gtk::Main::quit(); } -} // namespace gui -} // namespace ingen +} // namespace ingen::gui diff --git a/src/gui/GraphPortModule.cpp b/src/gui/GraphPortModule.cpp index 4c161f3f..ccbfbebf 100644 --- a/src/gui/GraphPortModule.cpp +++ b/src/gui/GraphPortModule.cpp @@ -42,9 +42,7 @@ #include <string> #include <utility> -namespace ingen { - -namespace gui { +namespace ingen::gui { GraphPortModule::GraphPortModule( GraphCanvas& canvas, @@ -169,5 +167,4 @@ GraphPortModule::set_selected(gboolean b) } } -} // namespace gui -} // namespace ingen +} // namespace ingen::gui diff --git a/src/gui/GraphPortModule.hpp b/src/gui/GraphPortModule.hpp index b02f63a1..56b4521a 100644 --- a/src/gui/GraphPortModule.hpp +++ b/src/gui/GraphPortModule.hpp @@ -33,9 +33,7 @@ class Atom; namespace client { class PortModel; } // namespace client -} // namespace ingen -namespace ingen { namespace gui { class App; diff --git a/src/gui/GraphWindow.cpp b/src/gui/GraphWindow.cpp index 94df34e0..4efaf4ae 100644 --- a/src/gui/GraphWindow.cpp +++ b/src/gui/GraphWindow.cpp @@ -26,8 +26,7 @@ #include <gtkmm/builder.h> #include <gtkmm/layout.h> -namespace ingen { -namespace gui { +namespace ingen::gui { GraphWindow::GraphWindow(BaseObjectType* cobject, const Glib::RefPtr<Gtk::Builder>& xml) @@ -80,5 +79,4 @@ GraphWindow::on_key_press_event(GdkEventKey* event) return Gtk::Window::on_key_press_event(event); } -} // namespace gui -} // namespace ingen +} // namespace ingen::gui diff --git a/src/gui/MessagesWindow.cpp b/src/gui/MessagesWindow.cpp index 9127ad61..7a382d51 100644 --- a/src/gui/MessagesWindow.cpp +++ b/src/gui/MessagesWindow.cpp @@ -39,8 +39,8 @@ #include <string> #include <utility> -namespace ingen { -namespace gui { +namespace ingen::gui { + using std::string; MessagesWindow::MessagesWindow(BaseObjectType* cobject, @@ -156,5 +156,4 @@ MessagesWindow::clear_clicked() _clear_button->set_sensitive(false); } -} // namespace gui -} // namespace ingen +} // namespace ingen::gui diff --git a/src/gui/MessagesWindow.hpp b/src/gui/MessagesWindow.hpp index 45301889..97b6187c 100644 --- a/src/gui/MessagesWindow.hpp +++ b/src/gui/MessagesWindow.hpp @@ -37,8 +37,7 @@ class Button; class TextView; } // namespace Gtk -namespace ingen { -namespace gui { +namespace ingen::gui { class App; @@ -75,7 +74,6 @@ private: std::map< LV2_URID, Glib::RefPtr<Gtk::TextTag> > _tags; }; -} // namespace gui -} // namespace ingen +} // namespace ingen::gui #endif // INGEN_GUI_MESSAGESWINDOW_HPP diff --git a/src/gui/NewSubgraphWindow.cpp b/src/gui/NewSubgraphWindow.cpp index 9b6c4a1a..086159a5 100644 --- a/src/gui/NewSubgraphWindow.cpp +++ b/src/gui/NewSubgraphWindow.cpp @@ -47,8 +47,7 @@ #include <string> #include <utility> -namespace ingen { -namespace gui { +namespace ingen::gui { NewSubgraphWindow::NewSubgraphWindow(BaseObjectType* cobject, const Glib::RefPtr<Gtk::Builder>& xml) @@ -138,5 +137,4 @@ NewSubgraphWindow::cancel_clicked() hide(); } -} // namespace gui -} // namespace ingen +} // namespace ingen::gui diff --git a/src/gui/NodeMenu.cpp b/src/gui/NodeMenu.cpp index faddaae7..2ebc223d 100644 --- a/src/gui/NodeMenu.cpp +++ b/src/gui/NodeMenu.cpp @@ -62,8 +62,7 @@ #include <utility> #include <vector> -namespace ingen { -namespace gui { +namespace ingen::gui { NodeMenu::NodeMenu(BaseObjectType* cobject, const Glib::RefPtr<Gtk::Builder>& xml) @@ -277,5 +276,4 @@ NodeMenu::has_control_inputs() return false; } -} // namespace gui -} // namespace ingen +} // namespace ingen::gui diff --git a/src/gui/NodeModule.hpp b/src/gui/NodeModule.hpp index f94a10e9..226dccd1 100644 --- a/src/gui/NodeModule.hpp +++ b/src/gui/NodeModule.hpp @@ -42,8 +42,7 @@ class PortModel; } // namespace client } // namespace ingen -namespace ingen { -namespace gui { +namespace ingen::gui { class App; class GraphCanvas; @@ -113,7 +112,6 @@ protected: bool _initialised{false}; }; -} // namespace gui -} // namespace ingen +} // namespace ingen::gui #endif // INGEN_GUI_NODEMODULE_HPP diff --git a/src/gui/ObjectMenu.cpp b/src/gui/ObjectMenu.cpp index 87f6f9e9..56055d1c 100644 --- a/src/gui/ObjectMenu.cpp +++ b/src/gui/ObjectMenu.cpp @@ -39,8 +39,7 @@ #include <cstdint> #include <memory> -namespace ingen { -namespace gui { +namespace ingen::gui { ObjectMenu::ObjectMenu(BaseObjectType* cobject, const Glib::RefPtr<Gtk::Builder>& xml) @@ -146,5 +145,4 @@ ObjectMenu::on_menu_properties() _app->window_factory()->present_properties(_object); } -} // namespace gui -} // namespace ingen +} // namespace ingen::gui diff --git a/src/gui/PluginMenu.cpp b/src/gui/PluginMenu.cpp index 1993a7a7..ac3c3981 100644 --- a/src/gui/PluginMenu.cpp +++ b/src/gui/PluginMenu.cpp @@ -32,8 +32,7 @@ #include <memory> #include <utility> -namespace ingen { -namespace gui { +namespace ingen::gui { PluginMenu::PluginMenu(ingen::World& world) : _world(world) @@ -183,5 +182,4 @@ PluginMenu::load_plugin(const std::weak_ptr<client::PluginModel>& weak_plugin) signal_load_plugin.emit(weak_plugin); } -} // namespace gui -} // namespace ingen +} // namespace ingen::gui diff --git a/src/gui/RDFS.cpp b/src/gui/RDFS.cpp index 3a277950..bba8c31f 100644 --- a/src/gui/RDFS.cpp +++ b/src/gui/RDFS.cpp @@ -26,9 +26,7 @@ #include <utility> -namespace ingen { -namespace gui { -namespace rdfs { +namespace ingen::gui::rdfs { std::string label(World& world, const LilvNode* node) @@ -257,6 +255,4 @@ is_a(World& world, const LilvNode* inst, const LilvNode* klass) return is_instance; } -} // namespace rdfs -} // namespace gui -} // namespace ingen +} // namespace ingen::gui::rdfs diff --git a/src/gui/RDFS.hpp b/src/gui/RDFS.hpp index 9a212dff..ad4e22e8 100644 --- a/src/gui/RDFS.hpp +++ b/src/gui/RDFS.hpp @@ -33,9 +33,7 @@ namespace client { class ObjectModel; } // namespace client -namespace gui { - -namespace rdfs { +namespace gui::rdfs { /** Set of URIs. */ using URISet = std::set<URI>; @@ -79,8 +77,7 @@ URISet range(World& world, const LilvNode* prop, bool recursive); /** Return true iff `inst` is-a `klass`. */ bool is_a(World& world, const LilvNode* inst, const LilvNode* klass); -} // namespace rdfs -} // namespace gui +} // namespace gui::rdfs } // namespace ingen #endif // INGEN_GUI_RDF_HPP diff --git a/src/gui/Style.cpp b/src/gui/Style.cpp index bce98648..9a9e7478 100644 --- a/src/gui/Style.cpp +++ b/src/gui/Style.cpp @@ -23,8 +23,7 @@ #include <string> -namespace ingen { -namespace gui { +namespace ingen::gui { Style::Style(App& app) : _app(app) @@ -97,5 +96,4 @@ Style::get_port_color(const client::PortModel* p) return 0x555555FF; } -} // namespace gui -} // namespace ingen +} // namespace ingen::gui diff --git a/src/gui/URIEntry.cpp b/src/gui/URIEntry.cpp index 4ae8da10..d701e3a2 100644 --- a/src/gui/URIEntry.cpp +++ b/src/gui/URIEntry.cpp @@ -35,8 +35,7 @@ #include <map> #include <utility> -namespace ingen { -namespace gui { +namespace ingen::gui { URIEntry::URIEntry(App* app, std::set<URI> types, const std::string& value) : Gtk::HBox(false, 4) @@ -203,5 +202,4 @@ URIEntry::menu_button_event(GdkEvent* ev) return true; } -} // namespace gui -} // namespace ingen +} // namespace ingen::gui diff --git a/src/gui/URIEntry.hpp b/src/gui/URIEntry.hpp index 04dfaa41..52c9db66 100644 --- a/src/gui/URIEntry.hpp +++ b/src/gui/URIEntry.hpp @@ -34,8 +34,7 @@ class Button; class Menu; } // namespace Gtk -namespace ingen { -namespace gui { +namespace ingen::gui { class App; @@ -73,7 +72,6 @@ private: Gtk::Entry* _entry; }; -} // namespace gui -} // namespace ingen +} // namespace ingen::gui #endif // INGEN_GUI_URI_ENTRY_HPP diff --git a/src/gui/WidgetFactory.cpp b/src/gui/WidgetFactory.cpp index d70a5084..dc08dbde 100644 --- a/src/gui/WidgetFactory.cpp +++ b/src/gui/WidgetFactory.cpp @@ -24,8 +24,7 @@ #include <stdexcept> #include <string> -namespace ingen { -namespace gui { +namespace ingen::gui { Glib::ustring WidgetFactory::ui_filename = ""; @@ -77,5 +76,4 @@ WidgetFactory::create(const std::string& toplevel_widget) return Gtk::Builder::create_from_file(ui_filename, toplevel_widget.c_str()); } -} // namespace gui -} // namespace ingen +} // namespace ingen::gui diff --git a/src/gui/WidgetFactory.hpp b/src/gui/WidgetFactory.hpp index d2f449ee..1c45fd6e 100644 --- a/src/gui/WidgetFactory.hpp +++ b/src/gui/WidgetFactory.hpp @@ -23,8 +23,7 @@ #include <string> -namespace ingen { -namespace gui { +namespace ingen::gui { /** Loads widgets from an XML description. * Purely static. @@ -54,7 +53,6 @@ private: static Glib::ustring ui_filename; }; -} // namespace gui -} // namespace ingen +} // namespace ingen::gui #endif // INGEN_GUI_WIDGETFACTORY_HPP diff --git a/src/gui/Window.hpp b/src/gui/Window.hpp index fa2016a8..756ba8f0 100644 --- a/src/gui/Window.hpp +++ b/src/gui/Window.hpp @@ -22,9 +22,7 @@ #include <gtkmm/dialog.h> #include <gtkmm/window.h> -namespace ingen { - -namespace gui { +namespace ingen::gui { class App; @@ -80,7 +78,6 @@ public: App* _app = nullptr; }; -} // namespace gui -} // namespace ingen +} // namespace ingen::gui #endif // INGEN_GUI_WINDOW_HPP diff --git a/src/gui/ingen_gui.cpp b/src/gui/ingen_gui.cpp index 329e098f..4c33c514 100644 --- a/src/gui/ingen_gui.cpp +++ b/src/gui/ingen_gui.cpp @@ -29,8 +29,7 @@ #include <memory> -namespace ingen { -namespace gui { +namespace ingen::gui { struct GUIModule : public Module { using SigClientInterface = client::SigClientInterface; @@ -63,8 +62,7 @@ struct GUIModule : public Module { std::shared_ptr<gui::App> app; }; -} // namespace gui -} // namespace ingen +} // namespace ingen::gui extern "C" { diff --git a/src/gui/rgba.hpp b/src/gui/rgba.hpp index 0d2c57aa..bb53205e 100644 --- a/src/gui/rgba.hpp +++ b/src/gui/rgba.hpp @@ -20,8 +20,7 @@ #include <cmath> #include <cstdint> -namespace ingen { -namespace gui { +namespace ingen::gui { inline uint32_t rgba_to_uint(uint8_t r, uint8_t g, uint8_t b, uint8_t a) @@ -53,7 +52,6 @@ rgba_interpolate(uint32_t c1, uint32_t c2, float f) mono_interpolate(RGBA_A(c1), RGBA_A(c2), f)); } -} // namespace gui -} // namespace ingen +} // namespace ingen::gui #endif // INGEN_GUI_RGBA_HPP diff --git a/src/server/ArcImpl.cpp b/src/server/ArcImpl.cpp index 689be199..0b503534 100644 --- a/src/server/ArcImpl.cpp +++ b/src/server/ArcImpl.cpp @@ -29,8 +29,7 @@ #include <cassert> #include <string> -namespace ingen { -namespace server { +namespace ingen::server { /** Constructor for an arc from a block's output port. * @@ -113,5 +112,4 @@ ArcImpl::can_connect(const PortImpl* src, const InputPort* dst) || (src->supports(uris.atom_Sound) && dst->is_a(PortType::ID::AUDIO))); } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/ArcImpl.hpp b/src/server/ArcImpl.hpp index 5e7e4357..27d7eacb 100644 --- a/src/server/ArcImpl.hpp +++ b/src/server/ArcImpl.hpp @@ -32,8 +32,7 @@ namespace raul { class Path; // IWYU pragma: keep } // namespace raul -namespace ingen { -namespace server { +namespace ingen::server { class InputPort; class PortImpl; @@ -83,7 +82,6 @@ protected: PortImpl* const _head; }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_ARC_IMPL_HPP diff --git a/src/server/BlockFactory.cpp b/src/server/BlockFactory.cpp index 2b80f037..5c9279d3 100644 --- a/src/server/BlockFactory.cpp +++ b/src/server/BlockFactory.cpp @@ -40,8 +40,7 @@ #include <utility> #include <vector> -namespace ingen { -namespace server { +namespace ingen::server { BlockFactory::BlockFactory(ingen::World& world) : _world(world) @@ -221,5 +220,4 @@ BlockFactory::load_lv2_plugins() _world.log().info("Loaded %1% plugins\n", _plugins.size()); } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/BlockImpl.cpp b/src/server/BlockImpl.cpp index 81474126..3fa7a1c3 100644 --- a/src/server/BlockImpl.cpp +++ b/src/server/BlockImpl.cpp @@ -32,8 +32,7 @@ #include <initializer_list> #include <string> -namespace ingen { -namespace server { +namespace ingen::server { BlockImpl::BlockImpl(PluginImpl* plugin, const raul::Symbol& symbol, @@ -297,5 +296,4 @@ BlockImpl::set_port_buffer(uint32_t, uint32_t, const BufferRef&, SampleCount) << " buffer " << buf << " offset " << offset << std::endl;*/ } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/BlockImpl.hpp b/src/server/BlockImpl.hpp index b845c612..3f742bfa 100644 --- a/src/server/BlockImpl.hpp +++ b/src/server/BlockImpl.hpp @@ -43,8 +43,7 @@ namespace raul { class Symbol; } // namespace raul -namespace ingen { -namespace server { +namespace ingen::server { class BufferFactory; class Engine; @@ -216,7 +215,6 @@ protected: bool _enabled{true}; }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_BLOCKIMPL_HPP diff --git a/src/server/Broadcaster.cpp b/src/server/Broadcaster.cpp index 04fbdba0..1d5cc843 100644 --- a/src/server/Broadcaster.cpp +++ b/src/server/Broadcaster.cpp @@ -25,8 +25,7 @@ #include <memory> #include <utility> -namespace ingen { -namespace server { +namespace ingen::server { Broadcaster::~Broadcaster() { @@ -92,5 +91,4 @@ Broadcaster::send_plugins_to(Interface* client, client->bundle_end(); } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/Broadcaster.hpp b/src/server/Broadcaster.hpp index 39acca04..e4034155 100644 --- a/src/server/Broadcaster.hpp +++ b/src/server/Broadcaster.hpp @@ -29,8 +29,7 @@ #include <mutex> #include <set> -namespace ingen { -namespace server { +namespace ingen::server { /** Broadcaster for all clients. * @@ -121,7 +120,6 @@ private: std::shared_ptr<Interface> _ignore_client; }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_BROADCASTER_HPP diff --git a/src/server/Buffer.cpp b/src/server/Buffer.cpp index f561871f..394d3323 100644 --- a/src/server/Buffer.cpp +++ b/src/server/Buffer.cpp @@ -38,8 +38,7 @@ # include <xmmintrin.h> #endif -namespace ingen { -namespace server { +namespace ingen::server { Buffer::Buffer(BufferFactory& bufs, LV2_URID type, @@ -458,5 +457,4 @@ intrusive_ptr_release(Buffer* b) b->deref(); } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/BufferFactory.cpp b/src/server/BufferFactory.cpp index 8ed4eaae..1afbf93f 100644 --- a/src/server/BufferFactory.cpp +++ b/src/server/BufferFactory.cpp @@ -28,8 +28,7 @@ #include <algorithm> #include <memory> -namespace ingen { -namespace server { +namespace ingen::server { BufferFactory::BufferFactory(Engine& engine, URIs& uris) : _free_audio(nullptr) @@ -199,5 +198,4 @@ BufferFactory::recycle(Buffer* buf) } while (!head_ptr.compare_exchange_weak(try_head, buf)); } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/BufferRef.hpp b/src/server/BufferRef.hpp index bb692001..cc5b840f 100644 --- a/src/server/BufferRef.hpp +++ b/src/server/BufferRef.hpp @@ -21,8 +21,7 @@ #include <boost/smart_ptr/intrusive_ptr.hpp> // IWYU pragma: export -namespace ingen { -namespace server { +namespace ingen::server { class Buffer; @@ -32,7 +31,6 @@ using BufferRef = boost::intrusive_ptr<Buffer>; INGEN_SERVER_API void intrusive_ptr_add_ref(Buffer* b); INGEN_SERVER_API void intrusive_ptr_release(Buffer* b); -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_BUFFER_REF_HPP diff --git a/src/server/ClientUpdate.cpp b/src/server/ClientUpdate.cpp index 5034257b..c96a0d01 100644 --- a/src/server/ClientUpdate.cpp +++ b/src/server/ClientUpdate.cpp @@ -38,8 +38,7 @@ #include <memory> #include <utility> -namespace ingen { -namespace server { +namespace ingen::server { void ClientUpdate::put(const URI& uri, @@ -166,5 +165,4 @@ ClientUpdate::send(Interface& dest) } } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/CompiledGraph.cpp b/src/server/CompiledGraph.cpp index f03187ae..b453932b 100644 --- a/src/server/CompiledGraph.cpp +++ b/src/server/CompiledGraph.cpp @@ -40,8 +40,7 @@ #include <memory> #include <utility> -namespace ingen { -namespace server { +namespace ingen::server { /** Graph contains ambiguous feedback with no delay nodes. */ class FeedbackException : public std::exception @@ -287,5 +286,4 @@ CompiledGraph::dump(const std::string& name) const sink(")\n"); } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/CompiledGraph.hpp b/src/server/CompiledGraph.hpp index f33941aa..a5ba66c3 100644 --- a/src/server/CompiledGraph.hpp +++ b/src/server/CompiledGraph.hpp @@ -27,8 +27,7 @@ #include <set> #include <string> -namespace ingen { -namespace server { +namespace ingen::server { class BlockImpl; class GraphImpl; @@ -79,7 +78,6 @@ compile(raul::Maid& maid, GraphImpl& graph) return CompiledGraph::compile(maid, graph); } -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_COMPILEDGRAPH_HPP diff --git a/src/server/ControlBindings.cpp b/src/server/ControlBindings.cpp index e222bce8..265333d4 100644 --- a/src/server/ControlBindings.cpp +++ b/src/server/ControlBindings.cpp @@ -42,8 +42,7 @@ #include <cstring> #include <string> -namespace ingen { -namespace server { +namespace ingen::server { ControlBindings::ControlBindings(Engine& engine) : _engine(engine) @@ -481,5 +480,4 @@ ControlBindings::post_process(RunContext&, Buffer* buffer) } } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/ControlBindings.hpp b/src/server/ControlBindings.hpp index d72fd2fd..9a7f66a2 100644 --- a/src/server/ControlBindings.hpp +++ b/src/server/ControlBindings.hpp @@ -34,13 +34,9 @@ namespace raul { class Path; } // namespace raul -namespace boost { -namespace intrusive { - +namespace boost::intrusive { template <class Compare> struct compare; - -} // namespace intrusive -} // namespace boost +} // namespace boost::intrusive namespace ingen { diff --git a/src/server/DirectDriver.hpp b/src/server/DirectDriver.hpp index 48de44f9..2361034c 100644 --- a/src/server/DirectDriver.hpp +++ b/src/server/DirectDriver.hpp @@ -31,13 +31,9 @@ #include <cstddef> #include <string> -namespace boost { -namespace intrusive { - +namespace boost::intrusive { template <bool Enabled> struct cache_last; - -} // namespace intrusive -} // namespace boost +} // namespace boost::intrusive namespace ingen { diff --git a/src/server/DuplexPort.cpp b/src/server/DuplexPort.cpp index 0c4c83e6..941beb10 100644 --- a/src/server/DuplexPort.cpp +++ b/src/server/DuplexPort.cpp @@ -38,8 +38,7 @@ #include <memory> #include <utility> -namespace ingen { -namespace server { +namespace ingen::server { DuplexPort::DuplexPort(BufferFactory& bufs, GraphImpl* parent, @@ -257,5 +256,4 @@ DuplexPort::next_value_offset(SampleCount offset, SampleCount end) const return PortImpl::next_value_offset(offset, end); } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/Engine.cpp b/src/server/Engine.cpp index 613def62..9603fcef 100644 --- a/src/server/Engine.cpp +++ b/src/server/Engine.cpp @@ -74,8 +74,7 @@ #include <thread> #include <utility> -namespace ingen { -namespace server { +namespace ingen::server { thread_local unsigned ThreadManager::flags(0); bool ThreadManager::single_threaded(true); @@ -531,5 +530,4 @@ Engine::unregister_client(const std::shared_ptr<Interface>& client) return _broadcaster->unregister_client(client); } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/EnginePort.hpp b/src/server/EnginePort.hpp index d6e67f1e..7a25bda5 100644 --- a/src/server/EnginePort.hpp +++ b/src/server/EnginePort.hpp @@ -26,8 +26,7 @@ #include <cstdint> -namespace ingen { -namespace server { +namespace ingen::server { /** A "system" port (e.g. a Jack port, an external port on Ingen). * @@ -59,7 +58,6 @@ protected: uint32_t _driver_index{0}; }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_ENGINE_PORT_HPP diff --git a/src/server/Event.hpp b/src/server/Event.hpp index 68b66c86..de1f2384 100644 --- a/src/server/Event.hpp +++ b/src/server/Event.hpp @@ -36,8 +36,7 @@ namespace raul { class Path; } // namespace raul -namespace ingen { -namespace server { +namespace ingen::server { class Engine; class RunContext; @@ -169,7 +168,6 @@ protected: Mode _mode; }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_EVENT_HPP diff --git a/src/server/EventWriter.cpp b/src/server/EventWriter.cpp index e61b7624..2feef347 100644 --- a/src/server/EventWriter.cpp +++ b/src/server/EventWriter.cpp @@ -31,8 +31,7 @@ #include <variant> -namespace ingen { -namespace server { +namespace ingen::server { EventWriter::EventWriter(Engine& engine) : _engine(engine) @@ -150,5 +149,4 @@ EventWriter::operator()(const Get& msg) _event_mode); } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/EventWriter.hpp b/src/server/EventWriter.hpp index a71242c1..ea35ceea 100644 --- a/src/server/EventWriter.hpp +++ b/src/server/EventWriter.hpp @@ -26,8 +26,7 @@ #include <memory> -namespace ingen { -namespace server { +namespace ingen::server { class Engine; @@ -80,7 +79,6 @@ private: SampleCount now() const; }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_EVENTWRITER_HPP diff --git a/src/server/FrameTimer.hpp b/src/server/FrameTimer.hpp index dfa5c46b..1f653f67 100644 --- a/src/server/FrameTimer.hpp +++ b/src/server/FrameTimer.hpp @@ -20,8 +20,7 @@ #include <cmath> #include <cstdint> -namespace ingen { -namespace server { +namespace ingen::server { /** Delay-locked loop for monotonic sample time. * @@ -104,7 +103,6 @@ private: bool initialized = false; }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_FRAMETIMER_HPP diff --git a/src/server/GraphImpl.cpp b/src/server/GraphImpl.cpp index 1ed6c37f..fedc5df8 100644 --- a/src/server/GraphImpl.cpp +++ b/src/server/GraphImpl.cpp @@ -44,8 +44,7 @@ #include <type_traits> #include <unordered_map> -namespace ingen { -namespace server { +namespace ingen::server { GraphImpl::GraphImpl(Engine& engine, const raul::Symbol& symbol, @@ -390,5 +389,4 @@ GraphImpl::build_ports_array(raul::Maid& maid) return result; } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/GraphImpl.hpp b/src/server/GraphImpl.hpp index 3746961a..1976fd4d 100644 --- a/src/server/GraphImpl.hpp +++ b/src/server/GraphImpl.hpp @@ -38,16 +38,11 @@ namespace raul { class Symbol; } // namespace raul -namespace boost { -namespace intrusive { - +namespace boost::intrusive { template <bool Enabled> struct constant_time_size; +} // namespace boost::intrusive -} // namespace intrusive -} // namespace boost - -namespace ingen { -namespace server { +namespace ingen::server { class ArcImpl; class BufferFactory; @@ -216,7 +211,6 @@ private: bool _process{false}; ///< True iff graph is enabled }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_GRAPHIMPL_HPP diff --git a/src/server/GraphPlugin.hpp b/src/server/GraphPlugin.hpp index b7a281f5..ac89c7a9 100644 --- a/src/server/GraphPlugin.hpp +++ b/src/server/GraphPlugin.hpp @@ -26,8 +26,7 @@ #include <string> -namespace ingen { -namespace server { +namespace ingen::server { class BlockImpl; class BufferFactory; @@ -66,7 +65,6 @@ private: const std::string _name; }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_GRAPHPLUGIN_HPP diff --git a/src/server/InputPort.cpp b/src/server/InputPort.cpp index 8547dc35..4a464ea8 100644 --- a/src/server/InputPort.cpp +++ b/src/server/InputPort.cpp @@ -37,8 +37,7 @@ #include <cstdlib> #include <memory> -namespace ingen { -namespace server { +namespace ingen::server { InputPort::InputPort(BufferFactory& bufs, BlockImpl* parent, @@ -261,5 +260,4 @@ InputPort::direct_connect() const && buffer(0)->type() != _bufs.uris().atom_Sequence; } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/InputPort.hpp b/src/server/InputPort.hpp index 72040a49..834a6d8a 100644 --- a/src/server/InputPort.hpp +++ b/src/server/InputPort.hpp @@ -34,13 +34,11 @@ namespace raul { class Symbol; } // namespace raul -namespace boost { -namespace intrusive { +namespace boost::intrusive { template <bool Enabled> struct constant_time_size; -} // namespace intrusive -} // namespace boost +} // namespace boost::intrusive namespace ingen { diff --git a/src/server/InternalBlock.hpp b/src/server/InternalBlock.hpp index 2357f405..9db7325a 100644 --- a/src/server/InternalBlock.hpp +++ b/src/server/InternalBlock.hpp @@ -24,8 +24,7 @@ namespace raul { class Symbol; } // namespace raul -namespace ingen { -namespace server { +namespace ingen::server { class Engine; class GraphImpl; @@ -52,7 +51,6 @@ public: void pre_process(RunContext& ctx) override; }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_BLOCKIMPL_HPP diff --git a/src/server/InternalPlugin.cpp b/src/server/InternalPlugin.cpp index 6c188c5e..e6535ab2 100644 --- a/src/server/InternalPlugin.cpp +++ b/src/server/InternalPlugin.cpp @@ -28,8 +28,7 @@ #include <utility> -namespace ingen { -namespace server { +namespace ingen::server { InternalPlugin::InternalPlugin(URIs& uris, const URI& uri, raul::Symbol symbol) : PluginImpl(uris, uris.ingen_Internal.urid_atom(), uri) @@ -76,5 +75,4 @@ InternalPlugin::instantiate(BufferFactory& bufs, return nullptr; } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/JackDriver.cpp b/src/server/JackDriver.cpp index 32029c6e..eafa0fa7 100644 --- a/src/server/JackDriver.cpp +++ b/src/server/JackDriver.cpp @@ -57,8 +57,7 @@ using jack_sample_t = jack_default_audio_sample_t; -namespace ingen { -namespace server { +namespace ingen::server { JackDriver::JackDriver(Engine& engine) : _engine(engine) @@ -533,5 +532,4 @@ JackDriver::_block_length_cb(jack_nframes_t nframes) return 0; } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/JackDriver.hpp b/src/server/JackDriver.hpp index 7a1dd2e0..8bb7cff3 100644 --- a/src/server/JackDriver.hpp +++ b/src/server/JackDriver.hpp @@ -42,13 +42,9 @@ namespace raul { class Path; } // namespace raul -namespace boost { -namespace intrusive { - +namespace boost::intrusive { template <bool Enabled> struct cache_last; - -} // namespace intrusive -} // namespace boost +} // namespace boost::intrusive namespace ingen { diff --git a/src/server/LV2Block.cpp b/src/server/LV2Block.cpp index 23e58d43..6dac1eec 100644 --- a/src/server/LV2Block.cpp +++ b/src/server/LV2Block.cpp @@ -56,8 +56,7 @@ #include <string> #include <utility> -namespace ingen { -namespace server { +namespace ingen::server { /** Partially construct a LV2Block. * @@ -774,5 +773,4 @@ LV2Block::set_port_buffer(uint32_t voice, buf ? buf->port_data(_ports->at(port_num)->type(), offset) : nullptr); } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/LV2Block.hpp b/src/server/LV2Block.hpp index 253008c0..fd446106 100644 --- a/src/server/LV2Block.hpp +++ b/src/server/LV2Block.hpp @@ -46,8 +46,7 @@ namespace raul { class Symbol; } // namespace raul -namespace boost { -namespace intrusive { +namespace boost::intrusive { template <bool Enabled> struct cache_last; @@ -55,8 +54,7 @@ struct cache_last; template <bool Enabled> struct constant_time_size; -} // namespace intrusive -} // namespace boost +} // namespace boost::intrusive namespace ingen { diff --git a/src/server/LV2Plugin.cpp b/src/server/LV2Plugin.cpp index 98234746..25ae9294 100644 --- a/src/server/LV2Plugin.cpp +++ b/src/server/LV2Plugin.cpp @@ -27,8 +27,7 @@ #include <cstdlib> #include <string> -namespace ingen { -namespace server { +namespace ingen::server { LV2Plugin::LV2Plugin(World& world, const LilvPlugin* lplugin) : PluginImpl(world.uris(), @@ -140,5 +139,4 @@ LV2Plugin::load_presets() PluginImpl::load_presets(); } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/LV2ResizeFeature.hpp b/src/server/LV2ResizeFeature.hpp index ddad2ea7..485695d7 100644 --- a/src/server/LV2ResizeFeature.hpp +++ b/src/server/LV2ResizeFeature.hpp @@ -26,8 +26,7 @@ #include <memory> -namespace ingen { -namespace server { +namespace ingen::server { struct ResizeFeature : public ingen::LV2Features::Feature { static LV2_Resize_Port_Status resize_port( @@ -62,7 +61,6 @@ struct ResizeFeature : public ingen::LV2Features::Feature { } }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_LV2RESIZEFEATURE_HPP diff --git a/src/server/Load.hpp b/src/server/Load.hpp index 4a30dd58..c2f1f3df 100644 --- a/src/server/Load.hpp +++ b/src/server/Load.hpp @@ -21,8 +21,7 @@ #include <cstdint> #include <limits> -namespace ingen { -namespace server { +namespace ingen::server { struct Load { void update(uint64_t time, uint64_t available) { @@ -56,7 +55,6 @@ struct Load { bool changed = false; }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_LOAD_HPP diff --git a/src/server/NodeImpl.cpp b/src/server/NodeImpl.cpp index 499300a2..c76c66d4 100644 --- a/src/server/NodeImpl.cpp +++ b/src/server/NodeImpl.cpp @@ -27,8 +27,7 @@ #include <map> #include <utility> -namespace ingen { -namespace server { +namespace ingen::server { NodeImpl::NodeImpl(const ingen::URIs& uris, NodeImpl* parent, @@ -54,5 +53,4 @@ NodeImpl::parent_graph() const return dynamic_cast<GraphImpl*>(reinterpret_cast<BlockImpl*>(_parent)); } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/PortAudioDriver.cpp b/src/server/PortAudioDriver.cpp index c80b25f3..11bca592 100644 --- a/src/server/PortAudioDriver.cpp +++ b/src/server/PortAudioDriver.cpp @@ -33,8 +33,7 @@ #include <cstring> #include <string> -namespace ingen { -namespace server { +namespace ingen::server { static bool pa_error(const char* msg, PaError err) @@ -282,5 +281,4 @@ PortAudioDriver::process_cb(const void* inputs, return 0; } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/PortAudioDriver.hpp b/src/server/PortAudioDriver.hpp index a624ee6e..9f17a100 100644 --- a/src/server/PortAudioDriver.hpp +++ b/src/server/PortAudioDriver.hpp @@ -36,14 +36,12 @@ namespace raul { class Path; } // namespace raul -namespace boost { -namespace intrusive { +namespace boost::intrusive { template <bool Enabled> struct cache_last; -} // namespace intrusive -} // namespace boost +} // namespace boost::intrusive namespace ingen { diff --git a/src/server/PortImpl.cpp b/src/server/PortImpl.cpp index 68613e65..307d9b73 100644 --- a/src/server/PortImpl.cpp +++ b/src/server/PortImpl.cpp @@ -39,8 +39,7 @@ #include <memory> #include <utility> -namespace ingen { -namespace server { +namespace ingen::server { static const uint32_t monitor_rate = 25.0; // Hz @@ -577,5 +576,4 @@ PortImpl::post_process(RunContext& ctx) monitor(ctx); } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/PostProcessor.cpp b/src/server/PostProcessor.cpp index 0e94efea..a97fc451 100644 --- a/src/server/PostProcessor.cpp +++ b/src/server/PostProcessor.cpp @@ -21,8 +21,7 @@ #include <cassert> -namespace ingen { -namespace server { +namespace ingen::server { class PreProcessContext; @@ -112,5 +111,4 @@ PostProcessor::process() _engine.emit_notifications(end_time); } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/PostProcessor.hpp b/src/server/PostProcessor.hpp index a29d60da..7b2a3035 100644 --- a/src/server/PostProcessor.hpp +++ b/src/server/PostProcessor.hpp @@ -22,8 +22,7 @@ #include <atomic> -namespace ingen { -namespace server { +namespace ingen::server { class Engine; class Event; @@ -67,7 +66,6 @@ private: std::atomic<FrameTime> _max_time; }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_POSTPROCESSOR_HPP diff --git a/src/server/PreProcessContext.hpp b/src/server/PreProcessContext.hpp index 72dc64c3..79e8ca68 100644 --- a/src/server/PreProcessContext.hpp +++ b/src/server/PreProcessContext.hpp @@ -24,8 +24,7 @@ #include <unordered_set> -namespace ingen { -namespace server { +namespace ingen::server { /** Event pre-processing context. * @@ -83,7 +82,6 @@ private: bool _in_bundle = false; }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_PREPROCESSCONTEXT_HPP diff --git a/src/server/PreProcessor.cpp b/src/server/PreProcessor.cpp index 7746d1db..5d719761 100644 --- a/src/server/PreProcessor.cpp +++ b/src/server/PreProcessor.cpp @@ -34,8 +34,7 @@ #include <cstdio> #include <memory> -namespace ingen { -namespace server { +namespace ingen::server { PreProcessor::PreProcessor(Engine& engine) : _engine(engine) @@ -246,5 +245,4 @@ PreProcessor::run() } } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/PreProcessor.hpp b/src/server/PreProcessor.hpp index c17e4d87..e0b0cc4a 100644 --- a/src/server/PreProcessor.hpp +++ b/src/server/PreProcessor.hpp @@ -27,8 +27,7 @@ #include <mutex> #include <thread> -namespace ingen { -namespace server { +namespace ingen::server { class Engine; class PostProcessor; @@ -84,7 +83,6 @@ private: std::thread _thread; }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_PREPROCESSOR_HPP diff --git a/src/server/RunContext.cpp b/src/server/RunContext.cpp index f4e9219c..2bac3140 100644 --- a/src/server/RunContext.cpp +++ b/src/server/RunContext.cpp @@ -37,8 +37,7 @@ #include <pthread.h> #include <sched.h> -namespace ingen { -namespace server { +namespace ingen::server { struct Notification { explicit Notification(PortImpl* p = nullptr, @@ -194,5 +193,4 @@ RunContext::run() } } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/RunContext.hpp b/src/server/RunContext.hpp index 30f87efd..a91a3e17 100644 --- a/src/server/RunContext.hpp +++ b/src/server/RunContext.hpp @@ -26,8 +26,7 @@ #include <memory> #include <thread> -namespace ingen { -namespace server { +namespace ingen::server { class Engine; class PortImpl; @@ -157,7 +156,6 @@ protected: bool _realtime{true}; ///< True iff context is hard realtime }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_RUNCONTEXT_HPP diff --git a/src/server/SocketListener.cpp b/src/server/SocketListener.cpp index ed874634..075d78cc 100644 --- a/src/server/SocketListener.cpp +++ b/src/server/SocketListener.cpp @@ -40,8 +40,7 @@ #include <string> #include <thread> -namespace ingen { -namespace server { +namespace ingen::server { static constexpr const char* const unix_scheme = "unix://"; @@ -196,5 +195,4 @@ ingen_listen(Engine* engine, raul::Socket* unix_sock, raul::Socket* net_sock) } } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/SocketListener.hpp b/src/server/SocketListener.hpp index 70a2d46b..65df5af5 100644 --- a/src/server/SocketListener.hpp +++ b/src/server/SocketListener.hpp @@ -19,8 +19,7 @@ #include <memory> #include <thread> -namespace ingen { -namespace server { +namespace ingen::server { class Engine; @@ -37,5 +36,4 @@ private: std::unique_ptr<std::thread> thread; }; -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/SocketServer.hpp b/src/server/SocketServer.hpp index 0531c44c..92bab5eb 100644 --- a/src/server/SocketServer.hpp +++ b/src/server/SocketServer.hpp @@ -37,8 +37,7 @@ #include <cstdio> #include <memory> -namespace ingen { -namespace server { +namespace ingen::server { /** The server side of an Ingen socket connection. */ class SocketServer @@ -86,7 +85,6 @@ private: std::shared_ptr<SocketWriter> _writer; }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_SERVER_SOCKET_SERVER_HPP diff --git a/src/server/State.hpp b/src/server/State.hpp index 201c6b86..673b175b 100644 --- a/src/server/State.hpp +++ b/src/server/State.hpp @@ -21,8 +21,7 @@ #include <memory> -namespace ingen { -namespace server { +namespace ingen::server { struct StateDeleter { void operator()(LilvState* state) { lilv_state_free(state); } @@ -30,7 +29,6 @@ struct StateDeleter { using StatePtr = std::unique_ptr<LilvState, StateDeleter>; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_STATE_HPP diff --git a/src/server/Task.cpp b/src/server/Task.cpp index 089a2f46..2b8ff0cd 100644 --- a/src/server/Task.cpp +++ b/src/server/Task.cpp @@ -24,8 +24,7 @@ #include <cstddef> #include <memory> -namespace ingen { -namespace server { +namespace ingen::server { void Task::run(RunContext& ctx) @@ -163,5 +162,4 @@ Task::dump(const std::function<void(const std::string&)>& sink, } } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/Task.hpp b/src/server/Task.hpp index 0a545655..e64d888c 100644 --- a/src/server/Task.hpp +++ b/src/server/Task.hpp @@ -26,8 +26,7 @@ #include <string> #include <utility> -namespace ingen { -namespace server { +namespace ingen::server { class BlockImpl; class RunContext; @@ -116,7 +115,6 @@ private: std::atomic<bool> _done{false}; ///< Completion phase }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_TASK_HPP diff --git a/src/server/ThreadManager.hpp b/src/server/ThreadManager.hpp index b25c6eed..07a01c2b 100644 --- a/src/server/ThreadManager.hpp +++ b/src/server/ThreadManager.hpp @@ -21,8 +21,7 @@ #include <cassert> -namespace ingen { -namespace server { +namespace ingen::server { enum ThreadFlag { THREAD_IS_REAL_TIME = 1, @@ -61,7 +60,6 @@ public: static thread_local unsigned flags; }; -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_THREADMANAGER_HPP diff --git a/src/server/UndoStack.cpp b/src/server/UndoStack.cpp index a88cc778..395a04cd 100644 --- a/src/server/UndoStack.cpp +++ b/src/server/UndoStack.cpp @@ -33,8 +33,7 @@ #define USTR(s) reinterpret_cast<const uint8_t*>(s) -namespace ingen { -namespace server { +namespace ingen::server { int UndoStack::start_entry() @@ -264,5 +263,4 @@ UndoStack::save(FILE* stream, const char* name) serd_writer_free(writer); } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/events/Connect.cpp b/src/server/events/Connect.cpp index 386ed74d..44c734a8 100644 --- a/src/server/events/Connect.cpp +++ b/src/server/events/Connect.cpp @@ -42,9 +42,7 @@ #include <set> #include <utility> -namespace ingen { -namespace server { -namespace events { +namespace ingen::server::events { Connect::Connect(Engine& engine, const std::shared_ptr<Interface>& client, @@ -195,6 +193,4 @@ Connect::undo(Interface& target) target.disconnect(_msg.tail, _msg.head); } -} // namespace events -} // namespace server -} // namespace ingen +} // namespace ingen::server::events diff --git a/src/server/events/Copy.cpp b/src/server/events/Copy.cpp index c62417e0..f6bcc62a 100644 --- a/src/server/events/Copy.cpp +++ b/src/server/events/Copy.cpp @@ -42,9 +42,7 @@ #include <string_view> #include <utility> -namespace ingen { -namespace server { -namespace events { +namespace ingen::server::events { Copy::Copy(Engine& engine, const std::shared_ptr<Interface>& client, @@ -230,6 +228,4 @@ Copy::undo(Interface& target) } } -} // namespace events -} // namespace server -} // namespace ingen +} // namespace ingen::server::events diff --git a/src/server/events/CreateBlock.cpp b/src/server/events/CreateBlock.cpp index 23a0d35e..73834fcb 100644 --- a/src/server/events/CreateBlock.cpp +++ b/src/server/events/CreateBlock.cpp @@ -48,8 +48,7 @@ #include <memory> #include <utility> -namespace ingen { -namespace server { +namespace ingen::server { class RunContext; @@ -201,5 +200,4 @@ CreateBlock::undo(Interface& target) } } // namespace events -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/events/CreateGraph.cpp b/src/server/events/CreateGraph.cpp index 54a1788e..bcc935bb 100644 --- a/src/server/events/CreateGraph.cpp +++ b/src/server/events/CreateGraph.cpp @@ -45,9 +45,7 @@ #include <memory> #include <utility> -namespace ingen { -namespace server { -namespace events { +namespace ingen::server::events { CreateGraph::CreateGraph(Engine& engine, const std::shared_ptr<Interface>& client, @@ -255,6 +253,4 @@ CreateGraph::undo(Interface& target) target.del(_graph->uri()); } -} // namespace events -} // namespace server -} // namespace ingen +} // namespace ingen::server::events diff --git a/src/server/events/CreatePort.cpp b/src/server/events/CreatePort.cpp index 6eee6ed7..7a01d0d9 100644 --- a/src/server/events/CreatePort.cpp +++ b/src/server/events/CreatePort.cpp @@ -45,9 +45,7 @@ #include <memory> #include <utility> -namespace ingen { -namespace server { -namespace events { +namespace ingen::server::events { CreatePort::CreatePort(Engine& engine, const std::shared_ptr<Interface>& client, @@ -224,6 +222,4 @@ CreatePort::undo(Interface& target) target.del(_graph_port->uri()); } -} // namespace events -} // namespace server -} // namespace ingen +} // namespace ingen::server::events diff --git a/src/server/events/Delete.cpp b/src/server/events/Delete.cpp index ec1af085..b64c81c0 100644 --- a/src/server/events/Delete.cpp +++ b/src/server/events/Delete.cpp @@ -50,8 +50,7 @@ #include <string> #include <string_view> -namespace ingen { -namespace server { +namespace ingen::server { class RunContext; @@ -233,5 +232,4 @@ Delete::undo(Interface& target) } } // namespace events -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/events/Delta.cpp b/src/server/events/Delta.cpp index af3d5b59..0b8cab39 100644 --- a/src/server/events/Delta.cpp +++ b/src/server/events/Delta.cpp @@ -57,8 +57,7 @@ #include <utility> #include <vector> -namespace ingen { -namespace server { +namespace ingen::server { class PreProcessContext; @@ -675,5 +674,4 @@ Delta::get_execution() const } } // namespace events -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/events/Disconnect.cpp b/src/server/events/Disconnect.cpp index 3526ac83..ef0cbd0b 100644 --- a/src/server/events/Disconnect.cpp +++ b/src/server/events/Disconnect.cpp @@ -47,8 +47,7 @@ #include <string> #include <utility> -namespace ingen { -namespace server { +namespace ingen::server { class RunContext; @@ -233,5 +232,4 @@ Disconnect::undo(Interface& target) } } // namespace events -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/events/DisconnectAll.cpp b/src/server/events/DisconnectAll.cpp index 7ae17632..957c6a6f 100644 --- a/src/server/events/DisconnectAll.cpp +++ b/src/server/events/DisconnectAll.cpp @@ -39,9 +39,7 @@ #include <set> #include <utility> -namespace ingen { -namespace server { -namespace events { +namespace ingen::server::events { DisconnectAll::DisconnectAll(Engine& engine, const std::shared_ptr<Interface>& client, @@ -193,6 +191,4 @@ DisconnectAll::adjacent_arcs(GraphImpl* const graph) return arcs; } -} // namespace events -} // namespace server -} // namespace ingen +} // namespace ingen::server::events diff --git a/src/server/events/Get.cpp b/src/server/events/Get.cpp index 389d9e48..f4cbb49d 100644 --- a/src/server/events/Get.cpp +++ b/src/server/events/Get.cpp @@ -37,9 +37,7 @@ #include <memory> #include <mutex> -namespace ingen { -namespace server { -namespace events { +namespace ingen::server::events { Get::Get(Engine& engine, const std::shared_ptr<Interface>& client, @@ -122,6 +120,4 @@ Get::post_process() } } -} // namespace events -} // namespace server -} // namespace ingen +} // namespace ingen::server::events diff --git a/src/server/events/Mark.cpp b/src/server/events/Mark.cpp index 27ca6630..97acdbbb 100644 --- a/src/server/events/Mark.cpp +++ b/src/server/events/Mark.cpp @@ -30,9 +30,7 @@ #include <unordered_set> #include <utility> -namespace ingen { -namespace server { -namespace events { +namespace ingen::server::events { Mark::Mark(Engine& engine, const std::shared_ptr<Interface>& client, @@ -136,6 +134,4 @@ Mark::get_execution() const return Execution::NORMAL; } -} // namespace events -} // namespace server -} // namespace ingen +} // namespace ingen::server::events diff --git a/src/server/events/Move.cpp b/src/server/events/Move.cpp index 8b7ee655..ea05d34c 100644 --- a/src/server/events/Move.cpp +++ b/src/server/events/Move.cpp @@ -29,8 +29,7 @@ #include <memory> #include <mutex> -namespace ingen { -namespace server { +namespace ingen::server { class EnginePort; @@ -92,5 +91,4 @@ Move::undo(Interface& target) } } // namespace events -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/events/SetPortValue.cpp b/src/server/events/SetPortValue.cpp index 8b425571..8b599354 100644 --- a/src/server/events/SetPortValue.cpp +++ b/src/server/events/SetPortValue.cpp @@ -33,9 +33,7 @@ #include <cassert> #include <memory> -namespace ingen { -namespace server { -namespace events { +namespace ingen::server::events { /** Internal */ SetPortValue::SetPortValue(Engine& engine, @@ -138,6 +136,4 @@ SetPortValue::post_process() } } -} // namespace events -} // namespace server -} // namespace ingen +} // namespace ingen::server::events diff --git a/src/server/events/Undo.cpp b/src/server/events/Undo.cpp index 9d6fcfaa..ea8c7d69 100644 --- a/src/server/events/Undo.cpp +++ b/src/server/events/Undo.cpp @@ -28,9 +28,7 @@ #include <deque> #include <memory> -namespace ingen { -namespace server { -namespace events { +namespace ingen::server::events { Undo::Undo(Engine& engine, const std::shared_ptr<Interface>& client, @@ -89,6 +87,4 @@ Undo::post_process() respond(); } -} // namespace events -} // namespace server -} // namespace ingen +} // namespace ingen::server::events diff --git a/src/server/ingen_jack.cpp b/src/server/ingen_jack.cpp index 0d3263be..9aedacad 100644 --- a/src/server/ingen_jack.cpp +++ b/src/server/ingen_jack.cpp @@ -26,8 +26,7 @@ #include <memory> #include <string> -namespace ingen { -namespace server { +namespace ingen::server { class Driver; @@ -53,8 +52,7 @@ struct JackModule : public Module { } }; -} // namespace server -} // namespace ingen +} // namespace ingen::server extern "C" { diff --git a/src/server/ingen_portaudio.cpp b/src/server/ingen_portaudio.cpp index 86fc76d9..0199413f 100644 --- a/src/server/ingen_portaudio.cpp +++ b/src/server/ingen_portaudio.cpp @@ -25,8 +25,7 @@ #include <memory> -namespace ingen { -namespace server { +namespace ingen::server { class Driver; @@ -46,8 +45,7 @@ struct PortAudioModule : public Module { } }; -} // namespace server -} // namespace ingen +} // namespace ingen::server extern "C" { diff --git a/src/server/internals/BlockDelay.cpp b/src/server/internals/BlockDelay.cpp index 68252fe4..516b7cf4 100644 --- a/src/server/internals/BlockDelay.cpp +++ b/src/server/internals/BlockDelay.cpp @@ -33,8 +33,7 @@ #include <memory> -namespace ingen { -namespace server { +namespace ingen::server { class RunContext; @@ -92,5 +91,4 @@ BlockDelayNode::run(RunContext& ctx) } } // namespace internals -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/internals/Controller.cpp b/src/server/internals/Controller.cpp index ccc6df01..898bd55b 100644 --- a/src/server/internals/Controller.cpp +++ b/src/server/internals/Controller.cpp @@ -41,8 +41,7 @@ #include <initializer_list> #include <memory> -namespace ingen { -namespace server { +namespace ingen::server { class GraphImpl; @@ -184,5 +183,4 @@ ControllerNode::control(RunContext& ctx, uint8_t control_num, uint8_t val, Frame } } // namespace internals -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/internals/Note.cpp b/src/server/internals/Note.cpp index 976e43f9..dd202451 100644 --- a/src/server/internals/Note.cpp +++ b/src/server/internals/Note.cpp @@ -44,8 +44,7 @@ // #define NOTE_DEBUG 1 -namespace ingen { -namespace server { +namespace ingen::server { class GraphImpl; @@ -436,5 +435,4 @@ NoteNode::channel_pressure(RunContext& ctx, FrameTime time, float amount) } } // namespace internals -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/internals/Time.cpp b/src/server/internals/Time.cpp index 651a2f36..ee97ac84 100644 --- a/src/server/internals/Time.cpp +++ b/src/server/internals/Time.cpp @@ -38,8 +38,7 @@ #include <memory> -namespace ingen { -namespace server { +namespace ingen::server { class GraphImpl; @@ -87,5 +86,4 @@ TimeNode::run(RunContext& ctx) } } // namespace internals -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/internals/Trigger.cpp b/src/server/internals/Trigger.cpp index 89a970fc..519b6d9f 100644 --- a/src/server/internals/Trigger.cpp +++ b/src/server/internals/Trigger.cpp @@ -41,8 +41,7 @@ #include <cmath> #include <memory> -namespace ingen { -namespace server { +namespace ingen::server { class GraphImpl; @@ -198,5 +197,4 @@ TriggerNode::note_off(RunContext& ctx, uint8_t note_num, FrameTime time) } } // namespace internals -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/mix.cpp b/src/server/mix.cpp index 9c578d11..db491e28 100644 --- a/src/server/mix.cpp +++ b/src/server/mix.cpp @@ -23,8 +23,7 @@ #include "lv2/atom/atom.h" #include "lv2/atom/util.h" -namespace ingen { -namespace server { +namespace ingen::server { static inline bool is_end(const Buffer* buf, const LV2_Atom_Event* ev) @@ -111,5 +110,4 @@ mix(const RunContext& ctx, } } -} // namespace server -} // namespace ingen +} // namespace ingen::server diff --git a/src/server/mix.hpp b/src/server/mix.hpp index 75e139d3..11a9a1d2 100644 --- a/src/server/mix.hpp +++ b/src/server/mix.hpp @@ -19,8 +19,7 @@ #include <cstdint> -namespace ingen { -namespace server { +namespace ingen::server { class Buffer; class RunContext; @@ -31,7 +30,6 @@ mix(const RunContext& ctx, const Buffer*const* srcs, uint32_t num_srcs); -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_MIX_HPP diff --git a/src/server/util.hpp b/src/server/util.hpp index 3c8d2058..2076aa62 100644 --- a/src/server/util.hpp +++ b/src/server/util.hpp @@ -29,8 +29,7 @@ # define REALTIME #endif -namespace ingen { -namespace server { +namespace ingen::server { /** Set flags to disable denormal processing. */ @@ -43,7 +42,6 @@ set_denormal_flags(ingen::Log& log) #endif } -} // namespace server -} // namespace ingen +} // namespace ingen::server #endif // INGEN_ENGINE_UTIL_HPP |