Expression Templates Library (ETL)
traits_base.hpp
1 //=======================================================================
2 // Copyright (c) 2023 Baptiste Wicht
3 // Distributed under the terms of the MIT License.
4 // (See accompanying file LICENSE or copy at
5 // http://opensource.org/licenses/MIT)
6 //=======================================================================
7 
8 #pragma once
9 
10 namespace etl {
11 
19 template <typename T>
20 struct etl_traits {
21  static constexpr bool is_etl = false;
22  static constexpr bool is_transformer = false;
23  static constexpr bool is_view = false;
24  static constexpr bool is_magic_view = false;
25  static constexpr bool is_fast = false;
26  static constexpr bool is_generator = false;
27 
31  static constexpr size_t dimensions() {
32  return 0;
33  }
34 };
35 
36 } //end of namespace etl
static constexpr bool is_etl
Indicates if T is an ETL type.
Definition: traits_base.hpp:21
static constexpr bool is_magic_view
Indicates if T is a magic view.
Definition: traits_base.hpp:24
Root namespace for the ETL library.
Definition: adapter.hpp:15
static constexpr size_t dimensions()
Return the number of dimensions of the expression.
Definition: traits_base.hpp:31
static constexpr bool is_transformer
Indicates if T is a transformer.
Definition: traits_base.hpp:22
static constexpr bool is_view
Indicates if T is a view.
Definition: traits_base.hpp:23
static constexpr bool is_fast
Indicates if T is a fast structure.
Definition: traits_base.hpp:25
static constexpr bool is_generator
Indicates if T is a generator expression.
Definition: traits_base.hpp:26