| Server IP : 217.160.0.135 / Your IP : 216.73.217.85 Web Server : Apache System : Linux www 6.18.52-i1-ampere #1203 SMP Mon Sep 14 18:29:59 CEST 2026 aarch64 User : sws1074145052 ( 1074145052) PHP Version : 8.3.32 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /usr/lib/python3/dist-packages/pythran/pythonic/include/types/ |
Upload File : |
#ifndef PYTHONIC_INCLUDE_TYPES_POINTER_HPP
#define PYTHONIC_INCLUDE_TYPES_POINTER_HPP
PYTHONIC_NS_BEGIN
namespace types
{
template <class T>
struct pointer {
T *data;
using reference = T &;
using const_reference = T const &;
using value_type = T;
reference operator[](long);
value_type operator[](long) const;
reference fast(long);
value_type fast(long) const;
};
}
PYTHONIC_NS_END
namespace std
{
template <size_t I, class T>
typename pythonic::types::pointer<T>::reference
get(pythonic::types::pointer<T> &t);
template <size_t I, class T>
typename pythonic::types::pointer<T>::value_type
get(pythonic::types::pointer<T> const &t);
template <size_t I, class T>
typename pythonic::types::pointer<T>::value_type
get(pythonic::types::pointer<T> &&t);
template <size_t I, class T>
struct tuple_element<I, pythonic::types::pointer<T>> {
typedef typename pythonic::types::pointer<T>::value_type type;
};
}
#ifdef ENABLE_PYTHON_MODULE
#include "pythonic/python/core.hpp"
PYTHONIC_NS_BEGIN
template <typename T>
struct to_python<types::pointer<T>> {
static PyObject *convert(types::pointer<T> const &v);
};
template <class T>
struct from_python<types::pointer<T>> {
static bool is_convertible(PyObject *obj);
static types::pointer<T> convert(PyObject *obj);
};
PYTHONIC_NS_END
#endif
#endif