From f1268ca3bf10ab136bafbd63894ce12353fa8690 Mon Sep 17 00:00:00 2001 From: Adrian Kummerlaender Date: Tue, 10 Feb 2015 18:40:05 +0100 Subject: Moved `Sort` list index deletion into `DeleteNth` function * as it is commonly required functionality and as such should be provided by this library --- src/list/operation/delete_nth.h | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 src/list/operation/delete_nth.h (limited to 'src/list/operation/delete_nth.h') diff --git a/src/list/operation/delete_nth.h b/src/list/operation/delete_nth.h new file mode 100644 index 0000000..03df12a --- /dev/null +++ b/src/list/operation/delete_nth.h @@ -0,0 +1,21 @@ +#ifndef TYPEASVALUE_SRC_LIST_OPERATION_DELETE_NTH_H_ +#define TYPEASVALUE_SRC_LIST_OPERATION_DELETE_NTH_H_ + +#include "list/operation/append.h" +#include "list/operation/take.h" +#include "list/operation/drop.h" + +namespace tav { + +template < + typename Index, + typename List +> +using DeleteNth = Append< + typename Take::type, + typename Drop>, List>::type +>; + +} + +#endif // TYPEASVALUE_SRC_LIST_OPERATION_DELETE_NTH_H_ -- cgit v1.2.3