From 3b2615fa6255898184260a043a59fca6294ab721 Mon Sep 17 00:00:00 2001 From: Martchus Date: Sun, 5 Feb 2023 20:17:32 +0100 Subject: [PATCH] Move `BE`/`LE` namespaces to the end so these functions can use previous helpers --- conversion/binaryconversion.h | 44 +++++++++++++++++------------------ 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/conversion/binaryconversion.h b/conversion/binaryconversion.h index 020c3e1..36b515a 100644 --- a/conversion/binaryconversion.h +++ b/conversion/binaryconversion.h @@ -79,28 +79,6 @@ namespace CppUtilities { -/*! - * \brief Encapsulates binary conversion functions using the big endian byte order. - * \sa Endianness - Wikipedia - */ -namespace BE { - -#define CONVERSION_UTILITIES_BINARY_CONVERSION_INTERNAL 0 -#include "./binaryconversionprivate.h" -#undef CONVERSION_UTILITIES_BINARY_CONVERSION_INTERNAL -} // namespace BE - -/*! - * \brief Encapsulates binary conversion functions using the little endian byte order. - * \sa Endianness - Wikipedia - */ -namespace LE { - -#define CONVERSION_UTILITIES_BINARY_CONVERSION_INTERNAL 1 -#include "./binaryconversionprivate.h" -#undef CONVERSION_UTILITIES_BINARY_CONVERSION_INTERNAL -} // namespace LE - /*! * \brief Returns the 8.8 fixed point representation converted from the specified 32-bit floating point number. */ @@ -191,6 +169,28 @@ CPP_UTILITIES_EXPORT constexpr std::uint64_t swapOrder(std::uint64_t value) #endif +/*! + * \brief Encapsulates binary conversion functions using the big endian byte order. + * \sa Endianness - Wikipedia + */ +namespace BE { + +#define CONVERSION_UTILITIES_BINARY_CONVERSION_INTERNAL 0 +#include "./binaryconversionprivate.h" +#undef CONVERSION_UTILITIES_BINARY_CONVERSION_INTERNAL +} // namespace BE + +/*! + * \brief Encapsulates binary conversion functions using the little endian byte order. + * \sa Endianness - Wikipedia + */ +namespace LE { + +#define CONVERSION_UTILITIES_BINARY_CONVERSION_INTERNAL 1 +#include "./binaryconversionprivate.h" +#undef CONVERSION_UTILITIES_BINARY_CONVERSION_INTERNAL +} // namespace LE + } // namespace CppUtilities #endif // CONVERSION_UTILITIES_BINARY_CONVERSION_H