From 6d517d937e4d431c4d6e04f51d397e0e9dd74255 Mon Sep 17 00:00:00 2001 From: Emily Boudreaux Date: Tue, 17 Jun 2025 09:43:43 -0400 Subject: [PATCH] refactor(network): updated network and network::approx8 to use composition module This is a very basic wrapper implimentation currently. This is sufficient to lock the interface down so that other code can target it. However, internally there is just a "convert" function. Eventually we should rework the code itself to use the composition module more directly. --- assets/static/atomic/meson.build | 3 ++- src/composition/meson.build | 2 +- src/composition/private/composition.cpp | 2 +- src/composition/public/composition.h | 7 ++----- 4 files changed, 6 insertions(+), 8 deletions(-) diff --git a/assets/static/atomic/meson.build b/assets/static/atomic/meson.build index 9e024aa..b5b79b7 100644 --- a/assets/static/atomic/meson.build +++ b/assets/static/atomic/meson.build @@ -1,3 +1,4 @@ species_weight_dep = declare_dependency( include_directories: include_directories('include'), -) \ No newline at end of file +) +message('✅ SERiF species_weight dependency declared') \ No newline at end of file diff --git a/src/composition/meson.build b/src/composition/meson.build index fe928d8..d97cbec 100644 --- a/src/composition/meson.build +++ b/src/composition/meson.build @@ -29,4 +29,4 @@ composition_dep = declare_dependency( ) # Make headers accessible -install_headers(composition_headers, subdir : '4DSSE/composition') \ No newline at end of file +install_headers(composition_headers, subdir : 'SERiF/composition') \ No newline at end of file diff --git a/src/composition/private/composition.cpp b/src/composition/private/composition.cpp index 98a3668..aad84dc 100644 --- a/src/composition/private/composition.cpp +++ b/src/composition/private/composition.cpp @@ -333,7 +333,7 @@ namespace serif::composition { return old_number_fractions; } - bool Composition::finalize(bool norm) { + bool Composition::finalize(const bool norm) { bool finalized = false; if (m_massFracMode) { finalized = finalizeMassFracMode(norm); diff --git a/src/composition/public/composition.h b/src/composition/public/composition.h index 861cc47..3dcf8a0 100644 --- a/src/composition/public/composition.h +++ b/src/composition/public/composition.h @@ -18,8 +18,7 @@ // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA // // *********************************************************************** */ -#ifndef COMPOSITION_H -#define COMPOSITION_H +#pragma once #include #include @@ -507,6 +506,4 @@ namespace serif::composition { Composition operator+(const Composition& other) const; }; -}; // namespace serif::composition - -#endif // COMPOSITION_H \ No newline at end of file +}; // namespace serif::composition \ No newline at end of file