Initial commit
This commit is contained in:
commit
4f4397b3e1
48 changed files with 2002 additions and 0 deletions
12
VectorFiller/atlas/collection/impl/fill_with.h
Normal file
12
VectorFiller/atlas/collection/impl/fill_with.h
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
#pragma once
|
||||
|
||||
#include <algorithm>
|
||||
|
||||
namespace atlas::collection::detail {
|
||||
template <typename Iter, typename F>
|
||||
void fill_with(Iter start, Iter end, F f)
|
||||
{
|
||||
std::for_each(start, end, [g = std::move(f)](auto& v) { v = g(); });
|
||||
}
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue