container: root: refactor scope for internal/common types

Avoid programmer/compiler confusion for internal/common types.
This commit is contained in:
2025-12-17 13:17:46 -08:00
parent e8374a6c1f
commit 0c35fe1edd
9 changed files with 116 additions and 100 deletions

View File

@@ -34,8 +34,6 @@
#include "../../src/hash.hh"
namespace type = dfi::internal::type;
//! \namespace dfi
//! \since docker-finance 1.0.0
namespace dfi
@@ -129,15 +127,16 @@ struct HashInterface : protected HashData
//! \brief Hash mock implementation
//! \since docker-finance 1.0.0
struct HashImpl : public ::dfi::internal::Transform<HashImpl>,
public type::Hash
public ::dfi::internal::type::Hash
{
//! \brief Implements trivial type mock Hash encoder
template <
typename t_hash,
typename t_decoded,
typename t_encoded,
std::enable_if_t<type::is_signature_with_trivial<t_decoded>, bool> =
true>
std::enable_if_t<
::dfi::internal::type::is_signature_with_trivial<t_decoded>,
bool> = true>
t_encoded encoder_impl(const t_decoded decoded)
{
static_assert(
@@ -155,7 +154,7 @@ struct HashInterface : protected HashData
typename t_decoded,
typename t_encoded,
std::enable_if_t<
type::has_const_iterator<t_decoded>::value
::dfi::internal::type::has_const_iterator<t_decoded>::value
&& !std::is_same_v<t_decoded, std::string_view>,
bool> = true>
t_encoded encoder_impl(const t_decoded& decoded)