Schnek
schnek::ArrayExpression< Operator, Length > Class Template Reference

#include <arrayexpression.hpp>

Public Types

typedef Operator::value_type value_type
 

Public Member Functions

SCHNEK_INLINE ArrayExpression (const Operator Op_)
 
SCHNEK_INLINE ArrayExpression (const ArrayExpression &Expr)
 
SCHNEK_INLINE value_type operator[] (size_t i) const
 

Static Public Attributes

static constexpr size_t length = Length
 

Detailed Description

template<class Operator, size_t Length>
class schnek::ArrayExpression< Operator, Length >

Expression template for the Array class. This template will be created when adding or subtracting Arrays and will allow performing expressions without temporary variables.

Todo:
Handle type promotion

Constructor & Destructor Documentation

◆ ArrayExpression() [1/2]

template<class Operator, size_t Length>
SCHNEK_INLINE schnek::ArrayExpression< Operator, Length >::ArrayExpression ( const Operator  Op_)
inline

Construct the expression by passing a reference

◆ ArrayExpression() [2/2]

template<class Operator, size_t Length>
SCHNEK_INLINE schnek::ArrayExpression< Operator, Length >::ArrayExpression ( const ArrayExpression< Operator, Length > &  Expr)
inline

Copy constructor

Member Function Documentation

◆ operator[]()

template<class Operator, size_t Length>
SCHNEK_INLINE value_type schnek::ArrayExpression< Operator, Length >::operator[] ( size_t  i) const
inline

Return the i-th element of the expression


The documentation for this class was generated from the following files: