OmniSciDB  72c90bc290
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
anonymous_namespace{RuntimeFunctions.cpp} Namespace Reference

Enumerations

enum  AggFuncType { AggFuncType::MIN, AggFuncType::MAX, AggFuncType::SUM }
 

Functions

template<AggFuncType AGG_FUNC_TYPE, typename AGG_TYPE >
AGG_TYPE agg_func (AGG_TYPE const lhs, AGG_TYPE const rhs)
 

Enumeration Type Documentation

enum anonymous_namespace{RuntimeFunctions.cpp}::AggFuncType
strong

Function Documentation

template<AggFuncType AGG_FUNC_TYPE, typename AGG_TYPE >
AGG_TYPE anonymous_namespace{RuntimeFunctions.cpp}::agg_func ( AGG_TYPE const  lhs,
AGG_TYPE const  rhs 
)
inline

Definition at line 834 of file RuntimeFunctions.cpp.

References MAX, and MIN.

Referenced by query_template().

834  {
835  if constexpr (AGG_FUNC_TYPE == AggFuncType::MIN) {
836  return std::min(lhs, rhs);
837  } else if constexpr (AGG_FUNC_TYPE == AggFuncType::MAX) {
838  return std::max(lhs, rhs);
839  } else {
840  return lhs + rhs;
841  }
842 }

+ Here is the caller graph for this function: