From 0888b52ba1f14e667983c9c9a30c635847f65e6b Mon Sep 17 00:00:00 2001 From: Roland Conybeare Date: Mon, 22 Apr 2024 16:04:26 -0400 Subject: [PATCH] xo-unit: refactor: retire native_unit_id --- include/xo/unit/dimension.hpp | 30 ------------------------------ 1 file changed, 30 deletions(-) diff --git a/include/xo/unit/dimension.hpp b/include/xo/unit/dimension.hpp index a4fe8746..63bf2bfb 100644 --- a/include/xo/unit/dimension.hpp +++ b/include/xo/unit/dimension.hpp @@ -44,36 +44,6 @@ namespace xo { } static constexpr std::size_t n_dim = static_cast(dim::n_dim); - - enum class native_unit_id { - gram, - meter, - second, - currency, - price - }; - - template - struct native_unit_for; - - template <> - struct native_unit_for { static constexpr auto value = native_unit_id::gram; }; - - template <> - struct native_unit_for { static constexpr auto value = native_unit_id::meter; }; - - template <> - struct native_unit_for { static constexpr auto value = native_unit_id::second; }; - - template <> - struct native_unit_for { static constexpr auto value = native_unit_id::currency; }; - - template <> - struct native_unit_for { static constexpr auto value = native_unit_id::price; }; - - template - constexpr auto native_unit_for_v = native_unit_for::value; - } /*namespace qty*/ } /*namespace xo*/