1#ifndef RBIMPL_STDCKDINT_H
2#define RBIMPL_STDCKDINT_H
22#include "ruby/internal/config.h"
23#include "ruby/internal/cast.h"
28# if __has_include(<stdckdint.h>)
30# define RBIMPL_HAVE_STDCKDINT_H
34#ifdef HAVE_STDCKDINT_H
36# define RBIMPL_HAVE_STDCKDINT_H
43# undef RBIMPL_HAVE_STDCKDINT_H
46#ifdef RBIMPL_HAVE_STDCKDINT_H
48# include <stdckdint.h>
50#elif RBIMPL_HAS_BUILTIN(__builtin_add_overflow)
51# define ckd_add(x, y, z) RBIMPL_CAST((bool)__builtin_add_overflow((y), (z), (x)))
52# define ckd_sub(x, y, z) RBIMPL_CAST((bool)__builtin_sub_overflow((y), (z), (x)))
53# define ckd_mul(x, y, z) RBIMPL_CAST((bool)__builtin_mul_overflow((y), (z), (x)))
54# define __STDC_VERSION_STDCKDINT_H__ 202311L
65# undef __STDC_VERSION_STDCKDINT_H__
Defines RBIMPL_HAS_BUILTIN.