preCICE
v3.1.2
Loading...
Searching...
No Matches
src
utils
span_tools.hpp
Go to the documentation of this file.
1
#pragma once
2
3
#include "
precice/span.hpp
"
4
5
namespace
precice
{
6
8
template
<
typename
T>
9
auto
refToSpan
(T &element)
10
{
11
return
precice::span<T>
{&element, 1};
12
}
13
14
}
// namespace precice
precice::span
A C++ 11 implementation of the non-owning C++20 std::span type.
Definition
span.hpp:284
precice
Main namespace of the precice library.
Definition
Acceleration.cpp:5
precice::refToSpan
auto refToSpan(T &element)
Wraps a single element into a span.
Definition
span_tools.hpp:9
span.hpp