Ruby: ext/rbconfig/sizeof/limits.c File Reference

Ruby 3.0.5p211 (2022-11-24 revision ba5cf0f7c52d4d35cc6a173c89eda98ceffa2dcf)

Macros | Functions
limits.c File Reference
`#include <limits.h>`
`#include "ruby/ruby.h"`

Go to the source code of this file.

## Macros
#define | MAX2NUM(name) ULONG2NUM(name ## _MAX)
#define | MIN2NUM(name) LONG2NUM(name ## _MIN)
#define | DEFINE(k, v) rb_hash_aset(h, rb_str_new_cstr(#k), v)

## Functions
void | Init_limits (void)

## Macro Definition Documentation

## ◆ DEFINE

#define DEFINE | ( |  | k,
|  |  | v
| ) |  | rb_hash_aset(h, rb_str_new_cstr(#k), v)

## ◆ MAX2NUM

#define MAX2NUM | ( |  | name | ) | ULONG2NUM(name ## _MAX)

## ◆ MIN2NUM

#define MIN2NUM | ( |  | name | ) | LONG2NUM(name ## _MIN)

## Function Documentation

## ◆ Init_limits()

void Init_limits | ( | void |  | ) |

Definition at line 14 of file limits.c.

References DBL2NUM, DBL_DIG, DBL_EPSILON, DBL_MANT_DIG, DBL_MAX, DBL_MAX_10_EXP, DBL_MAX_EXP, DBL_MIN, DBL_MIN_10_EXP, DBL_MIN_EXP, DEFINE, FIXNUM_MAX, FIXNUM_MIN, FLT_RADIX, INTPTR_MAX, INTPTR_MIN, LLONG_MAX, LLONG_MIN, LONG2NUM, LONG_MAX, LONG_MIN, MAX2NUM, MIN2NUM, OBJ_FREEZE, rb_define_const(), rb_define_module(), rb_hash_new(), SIZE, SIZE_MAX, SIZE_MIN, and UINTPTR_MAX.

Referenced by Init_sizeof().