aboutsummaryrefslogtreecommitdiff
path: root/src/list/operation/concatenate.h
blob: cf680c12fa8e817e627c8ffc8f7d11a442e815aa (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#ifndef TYPEASVALUE_SRC_LIST_OPERATION_CONCATENATE_H_
#define TYPEASVALUE_SRC_LIST_OPERATION_CONCATENATE_H_

#include "append.h"
#include "higher/fold.h"
#include "conditional/if.h"

namespace tav {

template <
	typename    Head,
	typename... Tail
>
using Concatenate = Fold<
	Append,
	void,
	If<
		Boolean<sizeof...(Tail) == 0>,
		Head,
		List<Head, Tail...>
	>
>;

}

#endif // TYPEASVALUE_SRC_LIST_OPERATION_CONCATENATE_H_