OpenFPM_pdata  4.1.0
Project that contain the implementation of distributed structures
 
Loading...
Searching...
No Matches
generate_array_constexpr< T, N, F > Struct Template Reference

Main class to generate constexpr compile-time array. More...

Detailed Description

template<class T, size_t N, template< size_t, size_t > class F>
struct generate_array_constexpr< T, N, F >

Main class to generate constexpr compile-time array.

A constexpr compile time array is for example

constexpr size_t array[5] = {1,2,3,4,5}

Metafunction definition

Usage

const size_t count = 5;
typedef typename ::generate_array_constexpr<size_t,count, MetaFunc>::result ct_test_ce;
// ct_test_ce::data is equivalent to constexpr size_t [5] = {5,6,7,8,9}
BOOST_REQUIRE_EQUAL(ct_calc,11ul);
[Metafunction definition]
Definition common.hpp:349
Parameters
Tis the type ot the output array
Nsize of the sequence
FMeta function it take two template arguments

Definition at line 120 of file ct_array.hpp.

#include <ct_array.hpp>

Public Types

typedef generate_array_constexpr_impl< T, N-1, N, F >::result result
 meta-function to generate compile time array
 

Member Typedef Documentation

◆ result

template<class T , size_t N, template< size_t, size_t > class F>
typedef generate_array_constexpr_impl<T,N-1,N,F>::result generate_array_constexpr< T, N, F >::result

meta-function to generate compile time array

Definition at line 122 of file ct_array.hpp.


The documentation for this struct was generated from the following file: