lib/dbus/Types: rename _MakeStructTypeAsString to ConcatTypeAsString

This commit is contained in:
Max Kellermann 2018-06-03 20:26:30 +02:00
parent 8d49c2d028
commit 234f8d287a
1 changed files with 7 additions and 4 deletions

View File

@ -81,20 +81,23 @@ struct DictEntryTypeTraits {
using VariantTypeTraits = BasicTypeTraits<DBUS_TYPE_VARIANT>;
/**
* Concatenate all TypeAsString members to one string.
*/
template<typename T, typename... ContainedTraits>
struct _MakeStructTypeAsString
struct ConcatTypeAsString
: TemplateString::Concat<typename T::TypeAsString,
_MakeStructTypeAsString<ContainedTraits...>> {};
ConcatTypeAsString<ContainedTraits...>> {};
template<typename T>
struct _MakeStructTypeAsString<T> : T::TypeAsString {};
struct ConcatTypeAsString<T> : T::TypeAsString {};
template<typename... ContainedTraits>
struct StructTypeTraits {
static constexpr int TYPE = DBUS_TYPE_STRUCT;
typedef TemplateString::Concat<TemplateString::CharAsString<DBUS_STRUCT_BEGIN_CHAR>,
_MakeStructTypeAsString<ContainedTraits...>,
ConcatTypeAsString<ContainedTraits...>,
TemplateString::CharAsString<DBUS_STRUCT_END_CHAR>> TypeAsString;
};