Templa 0.0.1-alpha
C++ Metaprogramming Utilities
|
Computes the maximum value from a container-like object at compile time. More...
#include <algorithms.hpp>
Public Types | |
using | type = typename decltype(e)::value_type |
The type of the elements in the container. |
Static Public Attributes | |
static constexpr std::size_t | size = e.size() |
The number of elements in the container. | |
static constexpr auto | value |
The maximum value computed at compile time from the container. |
Computes the maximum value from a container-like object at compile time.
Unpacks a constexpr container (e.g., std::array) and computes the maximum element using the max struct.
e | A container expression with known size and random access. @requires The container must satisfy the concepts::Container constraint. |
|
staticconstexpr |
The maximum value computed at compile time from the container.
Internally uses the max struct to evaluate the maximum by unpacking the elements.