| Server IP : 217.160.0.212 / Your IP : 216.73.216.141 Web Server : Apache System : Linux www 6.18.51-i1-ampere #1196 SMP Fri Sep 11 20:43:55 CEST 2026 aarch64 User : sws1073854427 ( 1073854427) PHP Version : 8.4.23 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /lib/python3/dist-packages/pythran/pythonic/include/utils/ |
Upload File : |
#ifndef PYTHONIC_INCLUDE_UTILS_NEUTRAL_HPP
#define PYTHONIC_INCLUDE_UTILS_NEUTRAL_HPP
#include "pythonic/include/operator_/iadd.hpp"
#include "pythonic/include/operator_/iand.hpp"
#include "pythonic/include/operator_/ior.hpp"
#include "pythonic/include/operator_/imul.hpp"
#include "pythonic/include/operator_/imax.hpp"
#include "pythonic/include/operator_/imin.hpp"
#include "pythonic/include/operator_/ixor.hpp"
PYTHONIC_NS_BEGIN
namespace utils
{
template <class Op, class T>
struct neutral;
template <class T>
struct neutral<operator_::functor::iadd, T> {
static T const value;
};
template <class T>
T const neutral<operator_::functor::iadd, T>::value = 0;
template <class T>
struct neutral<operator_::functor::iand, T> {
static T const value;
};
template <class T>
T const neutral<operator_::functor::iand, T>::value = (T)-1;
template <class T>
struct neutral<operator_::functor::ior, T> {
static T const value;
};
template <class T>
T const neutral<operator_::functor::ior, T>::value = 0;
template <class T>
struct neutral<operator_::functor::imul, T> {
static T const value;
};
template <class T>
T const neutral<operator_::functor::imul, T>::value = 1;
template <class T>
struct neutral<operator_::functor::imax, T> {
static T const value;
};
template <class T>
T const neutral<operator_::functor::imax, T>::value =
std::numeric_limits<T>::lowest();
template <class T>
struct neutral<operator_::functor::imin, T> {
static T const value;
};
template <class T>
T const neutral<operator_::functor::imin, T>::value =
std::numeric_limits<T>::max();
template <class T>
struct neutral<operator_::functor::ixor, T> {
static T const value;
};
template <class T>
T const neutral<operator_::functor::ixor, T>::value = 0;
}
PYTHONIC_NS_END
#endif