#include <limits>
#include <type_traits>
#include "ecvl/core/datatype.h"
Go to the source code of this file.
|
template<typename T , typename U > |
promote_superior_type_t< T, U > | ecvl::PromoteAdd (T lhs, U rhs) |
|
template<typename T , typename U > |
promote_superior_type_t< T, U > | ecvl::PromoteSub (T lhs, U rhs) |
|
template<typename T , typename U > |
promote_superior_type_t< T, U > | ecvl::PromoteMul (T lhs, U rhs) |
|
template<typename T , typename U > |
promote_superior_type_t< T, U > | ecvl::PromoteDiv (T lhs, U rhs) |
|
◆ PROMOTE_OPERATION
#define PROMOTE_OPERATION |
( |
|
op_name, |
|
|
|
op_symbol |
|
) |
| |
Value:template<typename T, typename U> \
promote_superior_type_t<T, U> Promote ## op_name(T lhs, U rhs) { \
using dsttype = promote_superior_type_t<T, U>; \
return static_cast<dsttype>(lhs) op_symbol static_cast<dsttype>(rhs); \
}
Definition at line 66 of file type_promotion.h.