Skip to content
Snippets Groups Projects
Commit 9188e7a8 authored by Raphael Grimm's avatar Raphael Grimm
Browse files

Add simox::alg::advanced to advance an iterator and get the result

parent 82df4f6d
No related branches found
No related tags found
No related merge requests found
......@@ -103,6 +103,7 @@ SET(INCLUDES
algorithm/apply.hpp
algorithm/get_map_keys_values.h
algorithm/minmax.h
algorithm/advanced.h
algorithm/string/string_tools.h
algorithm/string/string_conversion.h
algorithm/string/string_conversion_eigen.h
......
......@@ -2,6 +2,7 @@
// This file is generated!
#include "algorithm/advanced.h"
#include "algorithm/for_each_if.h"
#include "algorithm/get_map_keys_values.h"
#include "algorithm/minmax.h"
......
#pragma once
#include <iterator>
namespace simox::alg
{
decltype(auto) advanced(auto&& it, auto n)
{
auto copy = it;
std::advance(copy, n);
return copy;
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment