Ruby  2.4.2p198(2017-09-14revision59899)
Data Structures | Macros | Typedefs | Enumerations | Functions | Variables
internal.h File Reference
#include "ruby.h"
#include "ruby/encoding.h"
#include "ruby/io.h"
Include dependency graph for internal.h:

Go to the source code of this file.

Data Structures

struct  RBignum
 
struct  RRational
 
struct  RFloat
 
struct  RComplex
 
struct  RHash
 
struct  RStruct
 
struct  rb_deprecated_classext_struct
 
struct  rb_subclass_entry
 
struct  rb_classext_struct
 
struct  RClass
 
struct  RIMemo
 
struct  vm_svar
 
struct  vm_throw_data
 
struct  vm_ifunc_argc
 
struct  vm_ifunc
 
struct  MEMO
 
struct  cmp_opt_data
 
struct  rb_global_entry
 
struct  RBasicRaw
 
struct  rb_execarg
 

Macros

#define LIKELY(x)   RB_LIKELY(x)
 
#define UNLIKELY(x)   RB_UNLIKELY(x)
 
#define MAYBE_UNUSED(x)   x
 
#define WARN_UNUSED_RESULT(x)   x
 
#define VALGRIND_MAKE_MEM_DEFINED(p, n)   0
 
#define VALGRIND_MAKE_MEM_UNDEFINED(p, n)   0
 
#define numberof(array)   ((int)(sizeof(array) / sizeof((array)[0])))
 
#define __has_feature(x)   0
 
#define __has_extension   __has_feature
 
#define STATIC_ASSERT(name, expr)   typedef int static_assert_##name##_check[1 - 2*!(expr)]
 
#define SIGNED_INTEGER_TYPE_P(int_type)   (0 > ((int_type)0)-1)
 
#define SIGNED_INTEGER_MAX(sint_type)
 
#define SIGNED_INTEGER_MIN(sint_type)   (-SIGNED_INTEGER_MAX(sint_type)-1)
 
#define UNSIGNED_INTEGER_MAX(uint_type)   (~(uint_type)0)
 
#define TIMET_MAX_PLUS_ONE   (2*(double)(TIMET_MAX/2+1))
 
#define MUL_OVERFLOW_SIGNED_INTEGER_P(a, b, min, max)
 
#define MUL_OVERFLOW_FIXNUM_P(a, b)   MUL_OVERFLOW_SIGNED_INTEGER_P(a, b, FIXNUM_MIN, FIXNUM_MAX)
 
#define MUL_OVERFLOW_LONG_P(a, b)   MUL_OVERFLOW_SIGNED_INTEGER_P(a, b, LONG_MIN, LONG_MAX)
 
#define MUL_OVERFLOW_INT_P(a, b)   MUL_OVERFLOW_SIGNED_INTEGER_P(a, b, INT_MIN, INT_MAX)
 
#define swap16(x)   ((uint16_t)((((x)&0xFF)<<8) | (((x)>>8)&0xFF)))
 
#define swap32(x)
 
#define bit_length(x)
 
#define BDIGIT   unsigned int
 
#define SIZEOF_BDIGIT   SIZEOF_INT
 
#define BDIGIT_DBL   unsigned LONG_LONG
 
#define BDIGIT_DBL_SIGNED   LONG_LONG
 
#define PRI_BDIGIT_PREFIX   ""
 
#define PRI_BDIGIT_DBL_PREFIX   PRI_LL_PREFIX
 
#define SIZEOF_ACTUAL_BDIGIT   SIZEOF_BDIGIT
 
#define PRIdBDIGIT   PRI_BDIGIT_PREFIX"d"
 
#define PRIiBDIGIT   PRI_BDIGIT_PREFIX"i"
 
#define PRIoBDIGIT   PRI_BDIGIT_PREFIX"o"
 
#define PRIuBDIGIT   PRI_BDIGIT_PREFIX"u"
 
#define PRIxBDIGIT   PRI_BDIGIT_PREFIX"x"
 
#define PRIXBDIGIT   PRI_BDIGIT_PREFIX"X"
 
#define PRIdBDIGIT_DBL   PRI_BDIGIT_DBL_PREFIX"d"
 
#define PRIiBDIGIT_DBL   PRI_BDIGIT_DBL_PREFIX"i"
 
#define PRIoBDIGIT_DBL   PRI_BDIGIT_DBL_PREFIX"o"
 
#define PRIuBDIGIT_DBL   PRI_BDIGIT_DBL_PREFIX"u"
 
#define PRIxBDIGIT_DBL   PRI_BDIGIT_DBL_PREFIX"x"
 
#define PRIXBDIGIT_DBL   PRI_BDIGIT_DBL_PREFIX"X"
 
#define BIGNUM_EMBED_LEN_NUMBITS   3
 
#define BIGNUM_EMBED_LEN_MAX   (SIZEOF_VALUE*3/SIZEOF_ACTUAL_BDIGIT)
 
#define BIGNUM_SIGN_BIT   ((VALUE)FL_USER1)
 
#define BIGNUM_SIGN(b)   ((RBASIC(b)->flags & BIGNUM_SIGN_BIT) != 0)
 
#define BIGNUM_SET_SIGN(b, sign)
 
#define BIGNUM_POSITIVE_P(b)   BIGNUM_SIGN(b)
 
#define BIGNUM_NEGATIVE_P(b)   (!BIGNUM_SIGN(b))
 
#define BIGNUM_NEGATE(b)   (RBASIC(b)->flags ^= BIGNUM_SIGN_BIT)
 
#define BIGNUM_EMBED_FLAG   ((VALUE)FL_USER2)
 
#define BIGNUM_EMBED_LEN_MASK   ((VALUE)(FL_USER5|FL_USER4|FL_USER3))
 
#define BIGNUM_EMBED_LEN_SHIFT   (FL_USHIFT+BIGNUM_EMBED_LEN_NUMBITS)
 
#define BIGNUM_LEN(b)
 
#define BIGNUM_DIGITS(b)
 
#define BIGNUM_LENINT(b)   rb_long2int(BIGNUM_LEN(b))
 
#define RBIGNUM(obj)   (R_CAST(RBignum)(obj))
 
#define RRATIONAL(obj)   (R_CAST(RRational)(obj))
 
#define RRATIONAL_SET_NUM(rat, n)   RB_OBJ_WRITE((rat), &((struct RRational *)(rat))->num,(n))
 
#define RRATIONAL_SET_DEN(rat, d)   RB_OBJ_WRITE((rat), &((struct RRational *)(rat))->den,(d))
 
#define RFLOAT(obj)   (R_CAST(RFloat)(obj))
 
#define RCOMPLEX(obj)   (R_CAST(RComplex)(obj))
 
#define RCOMPLEX_SET_REAL(cmp, r)   RB_OBJ_WRITE((cmp), &((struct RComplex *)(cmp))->real,(r))
 
#define RCOMPLEX_SET_IMAG(cmp, i)   RB_OBJ_WRITE((cmp), &((struct RComplex *)(cmp))->imag,(i))
 
#define RHASH(obj)   (R_CAST(RHash)(obj))
 
#define RHASH_ITER_LEV(h)   (RHASH(h)->iter_lev)
 
#define RHASH_IFNONE(h)   (RHASH(h)->ifnone)
 
#define RHASH_SIZE(h)   (RHASH(h)->ntbl ? RHASH(h)->ntbl->num_entries : (st_index_t)0)
 
#define RSTRUCT_EMBED_LEN_MAX   RSTRUCT_EMBED_LEN_MAX
 
#define RSTRUCT_EMBED_LEN_MASK   RSTRUCT_EMBED_LEN_MASK
 
#define RSTRUCT_EMBED_LEN_SHIFT   RSTRUCT_EMBED_LEN_SHIFT
 
#define RSTRUCT_EMBED_LEN(st)
 
#define RSTRUCT_LEN(st)   rb_struct_len(st)
 
#define RSTRUCT_LENINT(st)   rb_long2int(RSTRUCT_LEN(st))
 
#define RSTRUCT_CONST_PTR(st)   rb_struct_const_ptr(st)
 
#define RSTRUCT_PTR(st)   ((VALUE *)RSTRUCT_CONST_PTR(RB_OBJ_WB_UNPROTECT_FOR(STRUCT, st)))
 
#define RSTRUCT_SET(st, idx, v)   RB_OBJ_WRITE(st, &RSTRUCT_CONST_PTR(st)[idx], (v))
 
#define RSTRUCT_GET(st, idx)   (RSTRUCT_CONST_PTR(st)[idx])
 
#define RSTRUCT(obj)   (R_CAST(RStruct)(obj))
 
#define SERIALT2NUM   ULONG2NUM
 
#define RCLASS_EXT(c)   (RCLASS(c)->ptr)
 
#define RCLASS_IV_TBL(c)   (RCLASS_EXT(c)->iv_tbl)
 
#define RCLASS_CONST_TBL(c)   (RCLASS_EXT(c)->const_tbl)
 
#define RCLASS_M_TBL(c)   (RCLASS(c)->m_tbl)
 
#define RCLASS_CALLABLE_M_TBL(c)   (RCLASS_EXT(c)->callable_m_tbl)
 
#define RCLASS_IV_INDEX_TBL(c)   (RCLASS_EXT(c)->iv_index_tbl)
 
#define RCLASS_ORIGIN(c)   (RCLASS_EXT(c)->origin_)
 
#define RCLASS_REFINED_CLASS(c)   (RCLASS_EXT(c)->refined_class)
 
#define RCLASS_SERIAL(c)   (RCLASS_EXT(c)->class_serial)
 
#define RICLASS_IS_ORIGIN   FL_USER5
 
#define IMEMO_DEBUG   0
 
#define IMEMO_FL_USHIFT   (FL_USHIFT + 3)
 
#define IMEMO_FL_USER0   FL_USER3
 
#define IMEMO_FL_USER1   FL_USER4
 
#define IMEMO_FL_USER2   FL_USER5
 
#define IMEMO_FL_USER3   FL_USER6
 
#define IMEMO_FL_USER4   FL_USER7
 
#define THROW_DATA_CONSUMED   IMEMO_FL_USER0
 
#define THROW_DATA_P(err)   RB_TYPE_P(((VALUE)err), T_IMEMO)
 
#define IFUNC_NEW(a, b, c)   ((struct vm_ifunc *)rb_imemo_new(imemo_ifunc, (VALUE)(a), (VALUE)(b), (VALUE)(c), 0))
 
#define MEMO_V1_SET(m, v)   RB_OBJ_WRITE((m), &(m)->v1, (v))
 
#define MEMO_V2_SET(m, v)   RB_OBJ_WRITE((m), &(m)->v2, (v))
 
#define MEMO_CAST(m)   ((struct MEMO *)m)
 
#define MEMO_NEW(a, b, c)   ((struct MEMO *)rb_imemo_new(imemo_memo, (VALUE)(a), (VALUE)(b), (VALUE)(c), 0))
 
#define roomof(x, y)   (((x) + (y) - 1) / (y))
 
#define type_roomof(x, y)   roomof(sizeof(x), sizeof(y))
 
#define MEMO_FOR(type, value)   ((type *)RARRAY_PTR(value))
 
#define NEW_MEMO_FOR(type, value)   ((value) = rb_ary_tmp_new_fill(type_roomof(type, VALUE)), MEMO_FOR(type, value))
 
#define NEW_PARTIAL_MEMO_FOR(type, value, member)
 
#define STRING_P(s)   (RB_TYPE_P((s), T_STRING) && CLASS_OF(s) == rb_cString)
 
#define rb_cFixnum   rb_cInteger
 
#define rb_cBignum   rb_cInteger
 
#define NEW_CMP_OPT_MEMO(type, value)   NEW_PARTIAL_MEMO_FOR(type, value, cmp_opt)
 
#define CMP_OPTIMIZABLE_BIT(type)   (1U << TOKEN_PASTE(cmp_opt_,type))
 
#define CMP_OPTIMIZABLE(data, type)
 
#define OPTIMIZED_CMP(a, b, data)
 
#define rb_name_err_raise_str(mesg, recv, name)   rb_exc_raise(rb_name_err_new(mesg, recv, name))
 
#define rb_name_err_raise(mesg, recv, name)   rb_name_err_raise_str(rb_fstring_cstr(mesg), (recv), (name))
 
#define ONLY_FOR_INTERNAL_USE(func)   ruby_only_for_internal_use(func)
 
#define rb_sys_fail_path(path)   rb_sys_fail_str(path)
 
#define rb_syserr_fail_path(err, path)   rb_syserr_fail_str((err), (path))
 
#define SIZED_REALLOC_N(var, type, n, old_n)   ((var)=(type*)ruby_sized_xrealloc((char*)(var), (n) * sizeof(type), (old_n) * sizeof(type)))
 
#define RB_NEWOBJ_OF(obj, type, klass, flags)
 
#define NEWOBJ_OF(obj, type, klass, flags)   RB_NEWOBJ_OF(obj,type,klass,flags)
 
#define RHASH_TBL_RAW(h)   rb_hash_tbl_raw(h)
 
#define HASH_DELETED   FL_USER1
 
#define HASH_PROC_DEFAULT   FL_USER2
 
#define FIXNUM_POSITIVE_P(num)   ((SIGNED_VALUE)(num) > (SIGNED_VALUE)INT2FIX(0))
 
#define FIXNUM_NEGATIVE_P(num)   ((SIGNED_VALUE)(num) < 0)
 
#define FIXNUM_ZERO_P(num)   ((num) == INT2FIX(0))
 
#define INT_NEGATIVE_P(x)   (FIXNUM_P(x) ? FIXNUM_NEGATIVE_P(x) : BIGNUM_NEGATIVE_P(x))
 
#define ROUND_DEFAULT   RUBY_NUM_ROUND_HALF_UP
 
#define ROUND_TO(mode, even, up, down)
 
#define ROUND_FUNC(mode, name)   ROUND_TO(mode, name##_half_even, name##_half_up, name##_half_down)
 
#define ROUND_CALL(mode, name, args)
 
#define RUBY_BIT_ROTL(v, n)   (((v) << (n)) | ((v) >> ((sizeof(v) * 8) - n)))
 
#define RUBY_BIT_ROTR(v, n)   (((v) >> (n)) | ((v) << ((sizeof(v) * 8) - n)))
 
#define rb_float_value(v)   rb_float_value_inline(v)
 
#define rb_float_new(d)   rb_float_new_inline(d)
 
#define RBASIC_CLEAR_CLASS(obj)   memset(&(((struct RBasicRaw *)((VALUE)(obj)))->klass), 0, sizeof(VALUE))
 
#define RBASIC_SET_CLASS_RAW(obj, cls)   memcpy(&((struct RBasicRaw *)((VALUE)(obj)))->klass, &(cls), sizeof(VALUE))
 
#define RBASIC_SET_CLASS(obj, cls)
 
#define USE_SYMBOL_GC   1
 
#define RB_MAX_GROUPS   (65536)
 
#define ARGVSTR2ARGC(argv_str)   (RSTRING_LEN(argv_str) / sizeof(char *) - 2)
 
#define ARGVSTR2ARGV(argv_str)   ((char **)RSTRING_PTR(argv_str) + 1)
 
#define rb_fstring_lit(str)   rb_fstring_new((str), rb_strlen_lit(str))
 
#define rb_fstring_literal(str)   rb_fstring_lit(str)
 
#define QUOTE(str)   rb_str_quote_unprintable(str)
 
#define QUOTE_ID(id)   rb_id_quote_unprintable(id)
 
#define STR_NOEMBED   FL_USER1
 
#define STR_SHARED   FL_USER2 /* = ELTS_SHARED */
 
#define STR_EMBED_P(str)   (!FL_TEST_RAW((str), STR_NOEMBED))
 
#define STR_SHARED_P(s)   FL_ALL_RAW((s), STR_NOEMBED|ELTS_SHARED)
 
#define is_ascii_string(str)   (rb_enc_str_coderange(str) == ENC_CODERANGE_7BIT)
 
#define is_broken_string(str)   (rb_enc_str_coderange(str) == ENC_CODERANGE_BROKEN)
 
#define Check_Type(v, t)
 
#define RB_OBJ_GC_FLAGS_MAX   5
 
#define RUBY_DTRACE_CREATE_HOOK(name, arg)   RUBY_DTRACE_HOOK(name##_CREATE, arg)
 
#define RUBY_DTRACE_HOOK(name, arg)
 
#define RB_OBJ_BUILTIN_TYPE(obj)   rb_obj_builtin_type(obj)
 
#define OBJ_BUILTIN_TYPE(obj)   RB_OBJ_BUILTIN_TYPE(obj)
 

Typedefs

typedef struct rb_subclass_entry rb_subclass_entry_t
 
typedef unsigned long rb_serial_t
 
typedef struct rb_classext_struct rb_classext_t
 
typedef void rb_check_funcall_hook(int, VALUE, ID, int, const VALUE *, VALUE)
 

Enumerations

enum  { RSTRUCT_EMBED_LEN_MAX = 3, RSTRUCT_EMBED_LEN_MASK = (RUBY_FL_USER2|RUBY_FL_USER1), RSTRUCT_EMBED_LEN_SHIFT = (RUBY_FL_USHIFT+1), RSTRUCT_ENUM_END }
 
enum  imemo_type {
  imemo_env = 0, imemo_cref = 1, imemo_svar = 2, imemo_throw_data = 3,
  imemo_ifunc = 4, imemo_memo = 5, imemo_ment = 6, imemo_iseq = 7,
  imemo_mask = 0x07
}
 
enum  { cmp_opt_Fixnum, cmp_opt_String, cmp_optimizable_count }
 
enum  ruby_num_rounding_mode { RUBY_NUM_ROUND_HALF_UP, RUBY_NUM_ROUND_HALF_EVEN, RUBY_NUM_ROUND_HALF_DOWN, RUBY_NUM_ROUND_DEFAULT = ROUND_DEFAULT }
 

Functions

static unsigned int nlz_int (unsigned int x)
 
static unsigned int nlz_long (unsigned long x)
 
static unsigned int nlz_intptr (uintptr_t x)
 
static unsigned int rb_popcount32 (uint32_t x)
 
static int rb_popcount64 (uint64_t x)
 
static int rb_popcount_intptr (uintptr_t x)
 
static int ntz_int32 (uint32_t x)
 
static int ntz_int64 (uint64_t x)
 
static int ntz_intptr (uintptr_t x)
 
static VALUE rb_fix_mul_fix (VALUE x, VALUE y)
 
static void rb_fix_divmod_fix (VALUE a, VALUE b, VALUE *divp, VALUE *modp)
 
static VALUE rb_fix_div_fix (VALUE x, VALUE y)
 
static VALUE rb_fix_mod_fix (VALUE x, VALUE y)
 
void ruby_init_setproctitle (int argc, char *argv[])
 
static long rb_struct_len (VALUE st)
 
static const VALUErb_struct_const_ptr (VALUE st)
 
void rb_class_subclass_add (VALUE super, VALUE klass)
 
void rb_class_remove_from_super_subclasses (VALUE)
 
int rb_singleton_class_internal_p (VALUE sklass)
 
static void RCLASS_SET_ORIGIN (VALUE klass, VALUE origin)
 
static VALUE RCLASS_SUPER (VALUE klass)
 
static VALUE RCLASS_SET_SUPER (VALUE klass, VALUE super)
 
static enum imemo_type imemo_type (VALUE imemo)
 
struct vm_ifuncrb_vm_ifunc_new (VALUE(*func)(ANYARGS), const void *data, int min_argc, int max_argc)
 
static struct vm_ifuncrb_vm_ifunc_proc_new (VALUE(*func)(ANYARGS), const void *data)
 
struct rb_global_entryrb_global_entry (ID)
 
VALUE rb_gvar_get (struct rb_global_entry *)
 
VALUE rb_gvar_set (struct rb_global_entry *, VALUE)
 
VALUE rb_gvar_defined (struct rb_global_entry *)
 
VALUE rb_ary_last (int, const VALUE *, VALUE)
 
void rb_ary_set_len (VALUE, long)
 
void rb_ary_delete_same (VALUE, VALUE)
 
VALUE rb_ary_tmp_new_fill (long capa)
 
VALUE rb_ary_at (VALUE, VALUE)
 
size_t rb_ary_memsize (VALUE)
 
double rb_big_fdiv_double (VALUE x, VALUE y)
 
VALUE rb_big_uminus (VALUE x)
 
VALUE rb_big_hash (VALUE)
 
VALUE rb_big_odd_p (VALUE)
 
VALUE rb_big_even_p (VALUE)
 
size_t rb_big_size (VALUE)
 
VALUE rb_integer_float_cmp (VALUE x, VALUE y)
 
VALUE rb_integer_float_eq (VALUE x, VALUE y)
 
VALUE rb_cstr_parse_inum (const char *str, ssize_t len, char **endp, int base)
 
VALUE rb_big_comp (VALUE x)
 
VALUE rb_big_aref (VALUE x, VALUE y)
 
VALUE rb_big_abs (VALUE x)
 
VALUE rb_big_size_m (VALUE big)
 
VALUE rb_big_bit_length (VALUE big)
 
VALUE rb_big_remainder (VALUE x, VALUE y)
 
VALUE rb_big_gt (VALUE x, VALUE y)
 
VALUE rb_big_ge (VALUE x, VALUE y)
 
VALUE rb_big_lt (VALUE x, VALUE y)
 
VALUE rb_big_le (VALUE x, VALUE y)
 
VALUE rb_class_boot (VALUE)
 A utility function that wraps class_alloc. More...
 
VALUE rb_class_inherited (VALUE, VALUE)
 Calls Class::inherited. More...
 
VALUE rb_make_metaclass (VALUE, VALUE)
 
VALUE rb_include_class_new (VALUE, VALUE)
 
void rb_class_foreach_subclass (VALUE klass, void(*f)(VALUE, VALUE), VALUE)
 
void rb_class_detach_subclasses (VALUE)
 
void rb_class_detach_module_subclasses (VALUE)
 
void rb_class_remove_from_module_subclasses (VALUE)
 
VALUE rb_obj_methods (int argc, const VALUE *argv, VALUE obj)
 
VALUE rb_obj_protected_methods (int argc, const VALUE *argv, VALUE obj)
 
VALUE rb_obj_private_methods (int argc, const VALUE *argv, VALUE obj)
 
VALUE rb_obj_public_methods (int argc, const VALUE *argv, VALUE obj)
 
int rb_obj_basic_to_s_p (VALUE)
 
VALUE rb_special_singleton_class (VALUE)
 
VALUE rb_singleton_class_clone_and_attach (VALUE obj, VALUE attach)
 
VALUE rb_singleton_class_get (VALUE obj)
 Returns the singleton class of obj, or nil if obj is not a singleton object. More...
 
void Init_class_hierarchy (void)
 
int rb_class_has_methods (VALUE c)
 
void rb_undef_methods_from (VALUE klass, VALUE super)
 
VALUE rb_invcmp (VALUE, VALUE)
 
int rb_dvar_defined (ID, const struct rb_block *)
 
int rb_local_defined (ID, const struct rb_block *)
 
 CONSTFUNC (const char *rb_insns_name(int i))
 
VALUE rb_insns_name_array (void)
 
VALUE rb_complex_plus (VALUE, VALUE)
 
VALUE rb_complex_mul (VALUE, VALUE)
 
VALUE rb_complex_abs (VALUE x)
 
VALUE rb_complex_sqrt (VALUE x)
 
VALUE rb_obj_is_fiber (VALUE)
 
void rb_fiber_reset_root_local_storage (VALUE)
 
void ruby_register_rollback_func_for_ensure (VALUE(*ensure_func)(ANYARGS), VALUE(*rollback_func)(ANYARGS))
 
 PRINTF_ARGS (void ruby_debug_printf(const char *,...), 1, 2)
 
void Init_enc (void)
 
void Init_ext (void)
 
ID rb_id_encoding (void)
 
 CONSTFUNC (void rb_gc_mark_encodings(void))
 
rb_encodingrb_enc_get_from_index (int index)
 
rb_encodingrb_enc_check_str (VALUE str1, VALUE str2)
 
int rb_encdb_replicate (const char *alias, const char *orig)
 
int rb_encdb_alias (const char *alias, const char *orig)
 
int rb_encdb_dummy (const char *name)
 
void rb_encdb_declare (const char *name)
 
void rb_enc_set_base (const char *name, const char *orig)
 
int rb_enc_set_dummy (int index)
 
void rb_encdb_set_unicode (int index)
 
 PUREFUNC (int rb_data_is_encoding(VALUE obj))
 
VALUE rb_f_send (int argc, VALUE *argv, VALUE recv)
 
VALUE rb_nmin_run (VALUE obj, VALUE num, int by, int rev, int ary)
 
void rb_report_bug_valist (VALUE file, int line, const char *fmt, va_list args)
 
 PRINTF_ARGS (void rb_compile_error_str(VALUE file, int line, void *enc, const char *fmt,...), 4, 5)
 
VALUE rb_syntax_error_append (VALUE, VALUE, int, int, rb_encoding *, const char *, va_list)
 
VALUE rb_check_backtrace (VALUE)
 
 NORETURN (void rb_async_bug_errno(const char *, int))
 
const char * rb_builtin_type_name (int t)
 
const char * rb_builtin_class_name (VALUE x)
 
 PRINTF_ARGS (void rb_enc_warn(rb_encoding *enc, const char *fmt,...), 2, 3)
 
VALUE rb_name_err_new (VALUE mesg, VALUE recv, VALUE method)
 
 NORETURN (void ruby_only_for_internal_use(const char *))
 
VALUE rb_refinement_module_get_refined_class (VALUE module)
 
void ruby_error_print (void)
 
VALUE rb_get_backtrace (VALUE info)
 
void rb_call_end_proc (VALUE data)
 
void rb_mark_end_proc (void)
 
VALUE rb_home_dir_of (VALUE user, VALUE result)
 
VALUE rb_default_home_dir (VALUE result)
 
VALUE rb_realpath_internal (VALUE basedir, VALUE path, int strict)
 
void rb_file_const (const char *, VALUE)
 
int rb_file_load_ok (const char *)
 
VALUE rb_file_expand_path_fast (VALUE, VALUE)
 
VALUE rb_file_expand_path_internal (VALUE, VALUE, int, int, VALUE)
 
VALUE rb_get_path_check_to_string (VALUE, int)
 
VALUE rb_get_path_check_convert (VALUE, VALUE, int)
 
void Init_File (void)
 
int ruby_is_fd_loadable (int fd)
 
void Init_heap (void)
 
void * ruby_mimmalloc (size_t size)
 
void ruby_mimfree (void *ptr)
 
void rb_objspace_set_event_hook (const rb_event_flag_t event)
 
void rb_gc_writebarrier_remember (VALUE obj)
 
void ruby_gc_set_params (int safe_level)
 
void rb_copy_wb_protected_attribute (VALUE dest, VALUE obj)
 
void * ruby_sized_xrealloc (void *ptr, size_t new_size, size_t old_size) RUBY_ATTR_ALLOC_SIZE((2))
 
void * ruby_sized_xrealloc2 (void *ptr, size_t new_count, size_t element_size, size_t old_count) RUBY_ATTR_ALLOC_SIZE((2
 
void void ruby_sized_xfree (void *x, size_t size)
 
void rb_gc_resurrect (VALUE ptr)
 
struct st_tablerb_hash_tbl_raw (VALUE hash)
 
VALUE rb_hash_has_key (VALUE hash, VALUE key)
 
VALUE rb_hash_default_value (VALUE hash, VALUE key)
 
VALUE rb_hash_set_default_proc (VALUE hash, VALUE proc)
 
long rb_objid_hash (st_index_t index)
 
long rb_dbl_long_hash (double d)
 
st_tablerb_init_identtable (void)
 
st_tablerb_init_identtable_with_size (st_index_t size)
 
VALUE rb_hash_compare_by_id_p (VALUE hash)
 
VALUE rb_hash_keys (VALUE hash)
 
VALUE rb_hash_values (VALUE hash)
 
VALUE rb_hash_rehash (VALUE hash)
 
int rb_hash_add_new_element (VALUE hash, VALUE key, VALUE val)
 
void rb_call_inits (void)
 
const char * ruby_get_inplace_mode (void)
 
void ruby_set_inplace_mode (const char *)
 
ssize_t rb_io_bufread (VALUE io, void *buf, size_t size)
 
void rb_stdio_set_default_encoding (void)
 
VALUE rb_io_flush_raw (VALUE, int)
 
size_t rb_io_memsize (const rb_io_t *)
 
VALUE rb_get_load_path (void)
 
VALUE rb_get_expanded_load_path (void)
 
int rb_require_internal (VALUE fname, int safe)
 
 NORETURN (void rb_load_fail(VALUE, const char *))
 
int Init_enc_set_filesystem_encoding (void)
 
VALUE rb_math_atan2 (VALUE, VALUE)
 
VALUE rb_math_cos (VALUE)
 
VALUE rb_math_cosh (VALUE)
 
VALUE rb_math_exp (VALUE)
 
VALUE rb_math_hypot (VALUE, VALUE)
 
VALUE rb_math_log (int argc, const VALUE *argv)
 
VALUE rb_math_sin (VALUE)
 
VALUE rb_math_sinh (VALUE)
 
VALUE rb_math_sqrt (VALUE)
 
void Init_newline (void)
 
int rb_num_to_uint (VALUE val, unsigned int *ret)
 
VALUE ruby_num_interval_step_size (VALUE from, VALUE to, VALUE step, int excl)
 
int ruby_float_step (VALUE from, VALUE to, VALUE step, int excl)
 
double ruby_float_mod (double x, double y)
 
int rb_num_negative_p (VALUE)
 
VALUE rb_int_succ (VALUE num)
 
VALUE rb_int_pred (VALUE num)
 
VALUE rb_int_uminus (VALUE num)
 
VALUE rb_float_uminus (VALUE num)
 
VALUE rb_int_plus (VALUE x, VALUE y)
 
VALUE rb_int_minus (VALUE x, VALUE y)
 
VALUE rb_int_mul (VALUE x, VALUE y)
 
VALUE rb_int_idiv (VALUE x, VALUE y)
 
VALUE rb_int_modulo (VALUE x, VALUE y)
 
VALUE rb_int_round (VALUE num, int ndigits, enum ruby_num_rounding_mode mode)
 
VALUE rb_int2str (VALUE num, int base)
 
VALUE rb_dbl_hash (double d)
 
VALUE rb_fix_plus (VALUE x, VALUE y)
 
VALUE rb_int_gt (VALUE x, VALUE y)
 
VALUE rb_float_gt (VALUE x, VALUE y)
 
VALUE rb_int_ge (VALUE x, VALUE y)
 
enum ruby_num_rounding_mode rb_num_get_rounding_option (VALUE opts)
 
double rb_int_fdiv_double (VALUE x, VALUE y)
 
VALUE rb_int_pow (VALUE x, VALUE y)
 
VALUE rb_float_pow (VALUE x, VALUE y)
 
VALUE rb_int_cmp (VALUE x, VALUE y)
 
VALUE rb_int_equal (VALUE x, VALUE y)
 
VALUE rb_int_divmod (VALUE x, VALUE y)
 
VALUE rb_int_and (VALUE x, VALUE y)
 
VALUE rb_int_lshift (VALUE x, VALUE y)
 
VALUE rb_int_div (VALUE x, VALUE y)
 
VALUE rb_int_abs (VALUE num)
 
VALUE rb_float_abs (VALUE flt)
 
static double rb_float_flonum_value (VALUE v)
 
static double rb_float_noflonum_value (VALUE v)
 
static double rb_float_value_inline (VALUE v)
 
static VALUE rb_float_new_inline (double d)
 
void rb_obj_copy_ivar (VALUE dest, VALUE obj)
 
 CONSTFUNC (VALUE rb_obj_equal(VALUE obj1, VALUE obj2))
 
 CONSTFUNC (VALUE rb_obj_not(VALUE obj))
 
VALUE rb_class_search_ancestor (VALUE klass, VALUE super)
 
 NORETURN (void rb_undefined_alloc(VALUE klass))
 
double rb_num_to_dbl (VALUE val)
 
VALUE rb_obj_dig (int argc, VALUE *argv, VALUE self, VALUE notfound)
 
VALUE rb_parser_get_yydebug (VALUE)
 
VALUE rb_parser_set_yydebug (VALUE, VALUE)
 
VALUE rb_parser_set_context (VALUE, const struct rb_block *, int)
 
void * rb_parser_load_file (VALUE parser, VALUE name)
 
int rb_is_const_name (VALUE name)
 
int rb_is_class_name (VALUE name)
 
int rb_is_global_name (VALUE name)
 
int rb_is_instance_name (VALUE name)
 
int rb_is_attrset_name (VALUE name)
 
int rb_is_local_name (VALUE name)
 
int rb_is_method_name (VALUE name)
 
int rb_is_junk_name (VALUE name)
 
 PUREFUNC (int rb_is_const_sym(VALUE sym))
 
ID rb_make_internal_id (void)
 
void rb_gc_free_dsymbol (VALUE)
 
ID rb_id_attrget (ID id)
 
VALUE rb_proc_location (VALUE self)
 
st_index_t rb_hash_proc (st_index_t hash, VALUE proc)
 
int rb_block_arity (void)
 
int rb_block_min_max_arity (int *max)
 
VALUE rb_func_proc_new (rb_block_call_func_t func, VALUE val)
 
VALUE rb_func_lambda_new (rb_block_call_func_t func, VALUE val, int min_argc, int max_argc)
 
rb_pid_t rb_fork_ruby (int *status)
 
void rb_last_status_clear (void)
 
VALUE rb_rational_uminus (VALUE self)
 
VALUE rb_rational_plus (VALUE self, VALUE other)
 
VALUE rb_lcm (VALUE x, VALUE y)
 
VALUE rb_rational_reciprocal (VALUE x)
 
VALUE rb_cstr_to_rat (const char *, int)
 
VALUE rb_rational_abs (VALUE self)
 
VALUE rb_rational_cmp (VALUE self, VALUE other)
 
VALUE rb_reg_compile (VALUE str, int options, const char *sourcefile, int sourceline)
 
VALUE rb_reg_check_preprocess (VALUE)
 
long rb_reg_search0 (VALUE, VALUE, long, int, int)
 
VALUE rb_reg_match_p (VALUE re, VALUE str, long pos)
 
void rb_backref_set_string (VALUE string, long pos, long len)
 
int rb_match_count (VALUE match)
 
int rb_match_nth_defined (int nth, VALUE match)
 
int rb_get_next_signal (void)
 
int rb_sigaltstack_size (void)
 
VALUE rb_fstring (VALUE)
 
VALUE rb_fstring_new (const char *ptr, long len)
 
VALUE rb_fstring_cstr (const char *str)
 
int rb_str_buf_cat_escaped_char (VALUE result, unsigned int c, int unicode_p)
 
int rb_str_symname_p (VALUE)
 
VALUE rb_str_quote_unprintable (VALUE)
 
VALUE rb_id_quote_unprintable (ID)
 
char * rb_str_fill_terminator (VALUE str, const int termlen)
 
void rb_str_change_terminator_length (VALUE str, const int oldtermlen, const int termlen)
 
VALUE rb_str_locktmp_ensure (VALUE str, VALUE(*func)(VALUE), VALUE arg)
 
VALUE rb_str_tmp_frozen_acquire (VALUE str)
 
void rb_str_tmp_frozen_release (VALUE str, VALUE tmp)
 
VALUE rb_str_chomp_string (VALUE str, VALUE chomp)
 
size_t rb_str_memsize (VALUE)
 
VALUE rb_sym_proc_call (ID mid, int argc, const VALUE *argv, VALUE passed_proc)
 
VALUE rb_sym_to_proc (VALUE sym)
 
VALUE rb_sym_intern_ascii (const char *ptr, long len)
 
VALUE rb_sym_intern_ascii_cstr (const char *ptr)
 
VALUE rb_struct_init_copy (VALUE copy, VALUE s)
 
VALUE rb_struct_lookup (VALUE s, VALUE idx)
 
struct timeval rb_time_timeval (VALUE)
 
VALUE rb_obj_is_mutex (VALUE obj)
 
VALUE rb_suppress_tracing (VALUE(*func)(VALUE), VALUE arg)
 
void rb_thread_execute_interrupts (VALUE th)
 
void rb_clear_trace_func (void)
 
VALUE rb_get_coverages (void)
 
VALUE rb_thread_shield_new (void)
 
VALUE rb_thread_shield_wait (VALUE self)
 
VALUE rb_thread_shield_release (VALUE self)
 
VALUE rb_thread_shield_destroy (VALUE self)
 
int rb_thread_to_be_killed (VALUE thread)
 
void rb_mutex_allow_trap (VALUE self, int val)
 
VALUE rb_uninterruptible (VALUE(*b_proc)(ANYARGS), VALUE data)
 
VALUE rb_mutex_owned_p (VALUE self)
 
void ruby_kill (rb_pid_t pid, int sig)
 
void Init_native_thread (void)
 
int rb_divert_reserved_fd (int fd)
 
size_t rb_econv_memsize (rb_econv_t *)
 
char * ruby_dtoa (double d_, int mode, int ndigits, int *decpt, int *sign, char **rve)
 
char * ruby_hdtoa (double d, const char *xdigs, int ndigits, int *decpt, int *sign, char **rve)
 
void rb_gc_mark_global_tbl (void)
 
size_t rb_generic_ivar_memsize (VALUE)
 
VALUE rb_search_class_path (VALUE)
 
VALUE rb_attr_delete (VALUE, ID)
 
VALUE rb_ivar_lookup (VALUE obj, ID id, VALUE undef)
 
void rb_autoload_str (VALUE mod, ID id, VALUE file)
 
void rb_deprecate_constant (VALUE mod, const char *name)
 
rb_serial_t rb_next_class_serial (void)
 
VALUE rb_obj_is_thread (VALUE obj)
 
void rb_vm_mark (void *ptr)
 
void Init_BareVM (void)
 
void Init_vm_objects (void)
 
 PUREFUNC (VALUE rb_vm_top_self(void))
 
void rb_thread_recycle_stack_release (VALUE *)
 
void rb_vm_change_state (void)
 
void rb_vm_inc_const_missing_count (void)
 
void rb_thread_mark (void *th)
 
const void ** rb_vm_get_insns_address_table (void)
 
VALUE rb_sourcefilename (void)
 
VALUE rb_source_location (int *pline)
 
const char * rb_source_loc (int *pline)
 
void rb_vm_pop_cfunc_frame (void)
 
int rb_vm_add_root_module (ID id, VALUE module)
 
void rb_vm_check_redefinition_by_prepend (VALUE klass)
 
VALUE rb_yield_refine_block (VALUE refinement, VALUE refinements)
 
VALUE ruby_vm_special_exception_copy (VALUE)
 
 PUREFUNC (st_table *rb_vm_fstring_table(void))
 
void rb_print_backtrace (void)
 
void Init_vm_eval (void)
 
VALUE rb_current_realfilepath (void)
 
VALUE rb_check_block_call (VALUE, ID, int, const VALUE *, rb_block_call_func_t, VALUE)
 
VALUE rb_check_funcall_with_hook (VALUE recv, ID mid, int argc, const VALUE *argv, rb_check_funcall_hook *hook, VALUE arg)
 
VALUE rb_check_funcall_default (VALUE, ID, int, const VALUE *, VALUE)
 
VALUE rb_catch_protect (VALUE t, rb_block_call_func *func, VALUE data, int *stateptr)
 
VALUE rb_yield_1 (VALUE val)
 
VALUE rb_yield_lambda (VALUE values)
 
VALUE rb_lambda_call (VALUE obj, ID mid, int argc, const VALUE *argv, rb_block_call_func_t bl_proc, int min_argc, int max_argc, VALUE data2)
 
VALUE rb_equal_opt (VALUE obj1, VALUE obj2)
 
void Init_eval_method (void)
 
int rb_method_defined_by (VALUE obj, ID mid, VALUE(*cfunc)(ANYARGS))
 
void Init_prelude (void)
 
void Init_vm_backtrace (void)
 
VALUE rb_vm_thread_backtrace (int argc, const VALUE *argv, VALUE thval)
 
VALUE rb_vm_thread_backtrace_locations (int argc, const VALUE *argv, VALUE thval)
 
VALUE rb_make_backtrace (void)
 
void rb_backtrace_print_as_bugreport (void)
 
int rb_backtrace_p (VALUE obj)
 
VALUE rb_backtrace_to_str_ary (VALUE obj)
 
VALUE rb_backtrace_to_location_ary (VALUE obj)
 
void rb_backtrace_print_to (VALUE output)
 
VALUE rb_vm_backtrace_object (void)
 
RUBY_SYMBOL_EXPORT_BEGIN const char * rb_objspace_data_type_name (VALUE obj)
 
VALUE rb_thread_io_blocking_region (rb_blocking_function_t *func, void *data1, int fd)
 
VALUE rb_big_mul_normal (VALUE x, VALUE y)
 
VALUE rb_big_mul_balance (VALUE x, VALUE y)
 
VALUE rb_big_mul_karatsuba (VALUE x, VALUE y)
 
VALUE rb_big_mul_toom3 (VALUE x, VALUE y)
 
VALUE rb_big_sq_fast (VALUE x)
 
VALUE rb_big_divrem_normal (VALUE x, VALUE y)
 
VALUE rb_big2str_poweroftwo (VALUE x, int base)
 
VALUE rb_big2str_generic (VALUE x, int base)
 
VALUE rb_str2big_poweroftwo (VALUE arg, int base, int badcheck)
 
VALUE rb_str2big_normal (VALUE arg, int base, int badcheck)
 
VALUE rb_str2big_karatsuba (VALUE arg, int base, int badcheck)
 
int rb_bug_reporter_add (void(*func)(FILE *, void *), void *data)
 
 NORETURN (void rb_unexpected_type(VALUE, int))
 
VALUE rb_hash_delete_entry (VALUE hash, VALUE key)
 
VALUE rb_ident_hash_new (void)
 
void rb_maygvl_fd_fix_cloexec (int fd)
 
int rb_gc_for_fd (int err)
 
void rb_write_error_str (VALUE mesg)
 
VALUE rb_int_positive_pow (long x, unsigned long y)
 
int rb_exec_async_signal_safe (const struct rb_execarg *e, char *errmsg, size_t errmsg_buflen)
 
rb_pid_t rb_fork_async_signal_safe (int *status, int(*chfunc)(void *, char *, size_t), void *charg, VALUE fds, char *errmsg, size_t errmsg_buflen)
 
VALUE rb_execarg_new (int argc, const VALUE *argv, int accept_shell)
 
struct rb_execargrb_execarg_get (VALUE execarg_obj)
 
VALUE rb_execarg_init (int argc, const VALUE *argv, int accept_shell, VALUE execarg_obj)
 
int rb_execarg_addopt (VALUE execarg_obj, VALUE key, VALUE val)
 
void rb_execarg_parent_start (VALUE execarg_obj)
 
void rb_execarg_parent_end (VALUE execarg_obj)
 
int rb_execarg_run_options (const struct rb_execarg *e, struct rb_execarg *s, char *errmsg, size_t errmsg_buflen)
 
VALUE rb_execarg_extract_options (VALUE execarg_obj, VALUE opthash)
 
void rb_execarg_setenv (VALUE execarg_obj, VALUE env)
 
VALUE rb_gcd (VALUE x, VALUE y)
 
VALUE rb_gcd_normal (VALUE self, VALUE other)
 
int ruby_thread_has_gvl_p (void)
 
unsigned long ruby_scan_digits (const char *str, ssize_t len, int base, size_t *retlen, int *overflow)
 
void rb_mark_generic_ivar (VALUE)
 
VALUE rb_const_missing (VALUE klass, VALUE name)
 
int rb_class_ivar_set (VALUE klass, ID vid, VALUE value)
 
st_tablerb_st_copy (VALUE obj, struct st_table *orig_tbl)
 
VALUE rb_wb_protected_newobj_of (VALUE, VALUE)
 
VALUE rb_wb_unprotected_newobj_of (VALUE, VALUE)
 
size_t rb_obj_memsize_of (VALUE)
 
void rb_gc_verify_internal_consistency (void)
 
size_t rb_obj_gc_flags (VALUE, ID[], size_t)
 
void rb_gc_mark_values (long n, const VALUE *values)
 
VALUE rb_imemo_new (enum imemo_type type, VALUE v1, VALUE v2, VALUE v3, VALUE v0)
 
static int rb_obj_builtin_type (VALUE obj)
 

Variables

const char ruby_digitmap []
 
VALUE rb_eEAGAIN
 
VALUE rb_eEWOULDBLOCK
 
VALUE rb_eEINPROGRESS
 
VALUEruby_initial_gc_stress_ptr
 
int ruby_disable_gc
 
const char ruby_exec_prefix []
 
const char ruby_initial_load_paths []
 
int ruby_enable_coredump
 
VALUE rb_cEncodingConverter
 
rb_encoding OnigEncodingUS_ASCII
 
rb_encoding OnigEncodingUTF_8
 
const char ruby_engine []
 
const signed char ruby_digit36_to_number_table []
 
const char ruby_hexdigits []
 

Macro Definition Documentation

◆ __has_extension

#define __has_extension   __has_feature

Definition at line 57 of file internal.h.

◆ __has_feature

#define __has_feature (   x)    0

Definition at line 53 of file internal.h.

◆ ARGVSTR2ARGC

#define ARGVSTR2ARGC (   argv_str)    (RSTRING_LEN(argv_str) / sizeof(char *) - 2)

Definition at line 1405 of file internal.h.

Referenced by rb_execarg_commandline().

◆ ARGVSTR2ARGV

#define ARGVSTR2ARGV (   argv_str)    ((char **)RSTRING_PTR(argv_str) + 1)

Definition at line 1406 of file internal.h.

Referenced by pipe_open(), proc_exec_cmd(), rb_execarg_commandline(), and rb_spawn_process().

◆ BDIGIT

#define BDIGIT   unsigned int

Definition at line 425 of file internal.h.

◆ BDIGIT_DBL

#define BDIGIT_DBL   unsigned LONG_LONG

Definition at line 427 of file internal.h.

◆ BDIGIT_DBL_SIGNED

#define BDIGIT_DBL_SIGNED   LONG_LONG

Definition at line 428 of file internal.h.

◆ BIGNUM_DIGITS

#define BIGNUM_DIGITS (   b)
Value:
((RBASIC(b)->flags & BIGNUM_EMBED_FLAG) ? \
RBIGNUM(b)->as.ary : \
RBIGNUM(b)->as.heap.digits)
#define RBIGNUM(obj)
Definition: internal.h:521
#define RBASIC(obj)
Definition: ruby.h:1204
#define BIGNUM_EMBED_FLAG
Definition: internal.h:506

Definition at line 515 of file internal.h.

Referenced by ibf_dump_object_bignum(), obj_free(), obj_memsize_of(), and w_object().

◆ BIGNUM_EMBED_FLAG

#define BIGNUM_EMBED_FLAG   ((VALUE)FL_USER2)

Definition at line 506 of file internal.h.

Referenced by bignew_1(), obj_free(), obj_memsize_of(), and rb_big_realloc().

◆ BIGNUM_EMBED_LEN_MASK

#define BIGNUM_EMBED_LEN_MASK   ((VALUE)(FL_USER5|FL_USER4|FL_USER3))

Definition at line 507 of file internal.h.

◆ BIGNUM_EMBED_LEN_MAX

#define BIGNUM_EMBED_LEN_MAX   (SIZEOF_VALUE*3/SIZEOF_ACTUAL_BDIGIT)

Definition at line 480 of file internal.h.

Referenced by bignew_1(), and rb_big_realloc().

◆ BIGNUM_EMBED_LEN_NUMBITS

#define BIGNUM_EMBED_LEN_NUMBITS   3

Definition at line 477 of file internal.h.

◆ BIGNUM_EMBED_LEN_SHIFT

#define BIGNUM_EMBED_LEN_SHIFT   (FL_USHIFT+BIGNUM_EMBED_LEN_NUMBITS)

Definition at line 508 of file internal.h.

◆ BIGNUM_LEN

#define BIGNUM_LEN (   b)

◆ BIGNUM_LENINT

#define BIGNUM_LENINT (   b)    rb_long2int(BIGNUM_LEN(b))

Definition at line 519 of file internal.h.

◆ BIGNUM_NEGATE

#define BIGNUM_NEGATE (   b)    (RBASIC(b)->flags ^= BIGNUM_SIGN_BIT)

Definition at line 504 of file internal.h.

Referenced by bigsub_int(), negate_lit(), and rb_big_uminus().

◆ BIGNUM_NEGATIVE_P

#define BIGNUM_NEGATIVE_P (   b)    (!BIGNUM_SIGN(b))

◆ BIGNUM_POSITIVE_P

#define BIGNUM_POSITIVE_P (   b)    BIGNUM_SIGN(b)

◆ BIGNUM_SET_SIGN

#define BIGNUM_SET_SIGN (   b,
  sign 
)
Value:
((sign) ? (RBASIC(b)->flags |= BIGNUM_SIGN_BIT) \
: (RBASIC(b)->flags &= ~BIGNUM_SIGN_BIT))
#define BIGNUM_SIGN_BIT
Definition: internal.h:496
#define RBASIC(obj)
Definition: ruby.h:1204

Definition at line 499 of file internal.h.

Referenced by bigdivrem(), bignew_1(), rb_cstr_parse_inum(), rb_integer_unpack(), and twocomp2abs_bang().

◆ BIGNUM_SIGN

#define BIGNUM_SIGN (   b)    ((RBASIC(b)->flags & BIGNUM_SIGN_BIT) != 0)

◆ BIGNUM_SIGN_BIT

#define BIGNUM_SIGN_BIT   ((VALUE)FL_USER1)

Definition at line 496 of file internal.h.

◆ bit_length

#define bit_length (   x)
Value:
(unsigned int) \
(sizeof(x) <= SIZEOF_INT ? SIZEOF_INT * CHAR_BIT - nlz_int((unsigned int)(x)) : \
SIZEOF_LONG * CHAR_BIT - nlz_long((unsigned long)(x)))
static unsigned int nlz_long(unsigned long x)
Definition: internal.h:167
static unsigned int nlz_int(unsigned int x)
Definition: internal.h:137
#define CHAR_BIT
Definition: ruby.h:196

Definition at line 417 of file internal.h.

Referenced by bary_mul_precheck(), big_shift2(), bigdivrem_single1(), rb_big_lshift(), rb_big_rshift(), rb_cstr_parse_inum(), rb_fix_bit_length(), and rb_str2big_poweroftwo().

◆ Check_Type

#define Check_Type (   v,
 
)
Value:
(!RB_TYPE_P((VALUE)(v), (t)) || \
((t) == RUBY_T_DATA && RTYPEDDATA_P(v)) ? \
rb_unexpected_type((VALUE)(v), (t)) : (void)0)
#define RB_TYPE_P(obj, type)
Definition: ruby.h:527
void rb_unexpected_type(VALUE x, int t)
Definition: error.c:700
unsigned long VALUE
Definition: ruby.h:85
#define RTYPEDDATA_P(v)
Definition: ruby.h:1115

Definition at line 1668 of file internal.h.

◆ CMP_OPTIMIZABLE

#define CMP_OPTIMIZABLE (   data,
  type 
)
Value:
(((data).opt_inited & CMP_OPTIMIZABLE_BIT(type)) ? \
((data).opt_methods & CMP_OPTIMIZABLE_BIT(type)) : \
(((data).opt_inited |= CMP_OPTIMIZABLE_BIT(type)), \
rb_method_basic_definition_p(TOKEN_PASTE(rb_c,type), id_cmp) && \
((data).opt_methods |= CMP_OPTIMIZABLE_BIT(type))))
#define CMP_OPTIMIZABLE_BIT(type)
Definition: internal.h:868
#define TOKEN_PASTE(x, y)
Definition: version.h:12
#define id_cmp
Definition: enum.c:27

Definition at line 869 of file internal.h.

Referenced by sort_2().

◆ CMP_OPTIMIZABLE_BIT

#define CMP_OPTIMIZABLE_BIT (   type)    (1U << TOKEN_PASTE(cmp_opt_,type))

Definition at line 868 of file internal.h.

◆ FIXNUM_NEGATIVE_P

#define FIXNUM_NEGATIVE_P (   num)    ((SIGNED_VALUE)(num) < 0)

Definition at line 1167 of file internal.h.

Referenced by int_neg_p(), and negative_int_p().

◆ FIXNUM_POSITIVE_P

#define FIXNUM_POSITIVE_P (   num)    ((SIGNED_VALUE)(num) > (SIGNED_VALUE)INT2FIX(0))

Definition at line 1166 of file internal.h.

Referenced by int_pos_p(), positive_int_p(), and rb_int_round().

◆ FIXNUM_ZERO_P

#define FIXNUM_ZERO_P (   num)    ((num) == INT2FIX(0))

◆ HASH_DELETED

#define HASH_DELETED   FL_USER1

Definition at line 1123 of file internal.h.

Referenced by hash_foreach_ensure(), hash_foreach_iter(), and rb_hash_delete_entry().

◆ HASH_PROC_DEFAULT

#define HASH_PROC_DEFAULT   FL_USER2

◆ IFUNC_NEW

#define IFUNC_NEW (   a,
  b,
 
)    ((struct vm_ifunc *)rb_imemo_new(imemo_ifunc, (VALUE)(a), (VALUE)(b), (VALUE)(c), 0))

Definition at line 808 of file internal.h.

Referenced by iseq_compile_each(), method_for_self(), and rb_vm_ifunc_new().

◆ IMEMO_DEBUG

#define IMEMO_DEBUG   0

Definition at line 726 of file internal.h.

◆ IMEMO_FL_USER0

#define IMEMO_FL_USER0   FL_USER3

◆ IMEMO_FL_USER1

#define IMEMO_FL_USER1   FL_USER4

◆ IMEMO_FL_USER2

#define IMEMO_FL_USER2   FL_USER5

◆ IMEMO_FL_USER3

#define IMEMO_FL_USER3   FL_USER6

Definition at line 760 of file internal.h.

◆ IMEMO_FL_USER4

#define IMEMO_FL_USER4   FL_USER7

Definition at line 761 of file internal.h.

◆ IMEMO_FL_USHIFT

#define IMEMO_FL_USHIFT   (FL_USHIFT + 3)

◆ INT_NEGATIVE_P

#define INT_NEGATIVE_P (   x)    (FIXNUM_P(x) ? FIXNUM_NEGATIVE_P(x) : BIGNUM_NEGATIVE_P(x))

◆ is_ascii_string

#define is_ascii_string (   str)    (rb_enc_str_coderange(str) == ENC_CODERANGE_7BIT)

◆ is_broken_string

#define is_broken_string (   str)    (rb_enc_str_coderange(str) == ENC_CODERANGE_BROKEN)

◆ LIKELY

#define LIKELY (   x)    RB_LIKELY(x)

Definition at line 26 of file internal.h.

◆ MAYBE_UNUSED

#define MAYBE_UNUSED (   x)    x

Definition at line 30 of file internal.h.

◆ MEMO_CAST

#define MEMO_CAST (   m)    ((struct MEMO *)m)

◆ MEMO_FOR

#define MEMO_FOR (   type,
  value 
)    ((type *)RARRAY_PTR(value))

◆ MEMO_NEW

#define MEMO_NEW (   a,
  b,
 
)    ((struct MEMO *)rb_imemo_new(imemo_memo, (VALUE)(a), (VALUE)(b), (VALUE)(c), 0))

◆ MEMO_V1_SET

#define MEMO_V1_SET (   m,
 
)    RB_OBJ_WRITE((m), &(m)->v1, (v))

◆ MEMO_V2_SET

#define MEMO_V2_SET (   m,
 
)    RB_OBJ_WRITE((m), &(m)->v2, (v))

Definition at line 832 of file internal.h.

Referenced by max_by_i(), member_i(), and min_by_i().

◆ MUL_OVERFLOW_FIXNUM_P

#define MUL_OVERFLOW_FIXNUM_P (   a,
 
)    MUL_OVERFLOW_SIGNED_INTEGER_P(a, b, FIXNUM_MIN, FIXNUM_MAX)

Definition at line 89 of file internal.h.

Referenced by int_pow(), and rb_fix_mul_fix().

◆ MUL_OVERFLOW_INT_P

#define MUL_OVERFLOW_INT_P (   a,
 
)    MUL_OVERFLOW_SIGNED_INTEGER_P(a, b, INT_MIN, INT_MAX)

Definition at line 91 of file internal.h.

Referenced by get_num().

◆ MUL_OVERFLOW_LONG_P

#define MUL_OVERFLOW_LONG_P (   a,
 
)    MUL_OVERFLOW_SIGNED_INTEGER_P(a, b, LONG_MIN, LONG_MAX)

Definition at line 90 of file internal.h.

Referenced by f_imul(), and rb_ary_product().

◆ MUL_OVERFLOW_SIGNED_INTEGER_P

#define MUL_OVERFLOW_SIGNED_INTEGER_P (   a,
  b,
  min,
  max 
)
Value:
( \
(a) == 0 ? 0 : \
(a) == -1 ? (b) < -(max) : \
(a) > 0 ? \
((b) > 0 ? (max) / (a) < (b) : (min) / (a) > (b)) : \
((b) > 0 ? (min) / (a) < (b) : (max) / (a) > (b)))
static int max(int a, int b)
Definition: strftime.c:142

Definition at line 83 of file internal.h.

◆ NEW_CMP_OPT_MEMO

#define NEW_CMP_OPT_MEMO (   type,
  value 
)    NEW_PARTIAL_MEMO_FOR(type, value, cmp_opt)

Definition at line 866 of file internal.h.

Referenced by enum_max(), enum_min(), and enum_minmax().

◆ NEW_MEMO_FOR

#define NEW_MEMO_FOR (   type,
  value 
)    ((value) = rb_ary_tmp_new_fill(type_roomof(type, VALUE)), MEMO_FOR(type, value))

Definition at line 841 of file internal.h.

Referenced by chunk_i(), enum_minmax_by(), sliceafter_i(), and slicebefore_i().

◆ NEW_PARTIAL_MEMO_FOR

#define NEW_PARTIAL_MEMO_FOR (   type,
  value,
  member 
)
Value:
((value) = rb_ary_tmp_new_fill(type_roomof(type, VALUE)), \
rb_ary_set_len((value), offsetof(type, member) / sizeof(VALUE)), \
MEMO_FOR(type, value))
#define type_roomof(x, y)
Definition: internal.h:839
void rb_ary_set_len(VALUE, long)
Definition: array.c:1627
VALUE rb_ary_tmp_new_fill(long capa)
Definition: array.c:538
#define offsetof(p_type, field)
Definition: addrinfo.h:186
unsigned long VALUE
Definition: ruby.h:85

Definition at line 843 of file internal.h.

Referenced by slicewhen_i().

◆ NEWOBJ_OF

#define NEWOBJ_OF (   obj,
  type,
  klass,
  flags 
)    RB_NEWOBJ_OF(obj,type,klass,flags)

Definition at line 1105 of file internal.h.

◆ numberof

#define numberof (   array)    ((int)(sizeof(array) / sizeof((array)[0])))

Definition at line 50 of file internal.h.

◆ OBJ_BUILTIN_TYPE

#define OBJ_BUILTIN_TYPE (   obj)    RB_OBJ_BUILTIN_TYPE(obj)

Definition at line 1766 of file internal.h.

Referenced by objspace_internal_super_of(), and rb_file_join().

◆ ONLY_FOR_INTERNAL_USE

#define ONLY_FOR_INTERNAL_USE (   func)    ruby_only_for_internal_use(func)

◆ OPTIMIZED_CMP

#define OPTIMIZED_CMP (   a,
  b,
  data 
)
Value:
((FIXNUM_P(a) && FIXNUM_P(b) && CMP_OPTIMIZABLE(data, Fixnum)) ? \
(((long)a > (long)b) ? 1 : ((long)a < (long)b) ? -1 : 0) : \
(STRING_P(a) && STRING_P(b) && CMP_OPTIMIZABLE(data, String)) ? \
rb_str_cmp(a, b) : \
rb_cmpint(rb_funcallv(a, id_cmp, 1, &b), a, b))
#define STRING_P(s)
Definition: internal.h:848
int rb_str_cmp(VALUE, VALUE)
Definition: string.c:3050
#define FIXNUM_P(f)
Definition: ruby.h:365
#define CMP_OPTIMIZABLE(data, type)
Definition: internal.h:869
#define id_cmp
Definition: enum.c:27
#define rb_funcallv
Definition: console.c:21

Definition at line 876 of file internal.h.

Referenced by max_i(), min_i(), minmax_i(), minmax_i_update(), rb_ary_max(), and rb_ary_min().

◆ PRI_BDIGIT_DBL_PREFIX

#define PRI_BDIGIT_DBL_PREFIX   PRI_LL_PREFIX

Definition at line 430 of file internal.h.

◆ PRI_BDIGIT_PREFIX

#define PRI_BDIGIT_PREFIX   ""

Definition at line 429 of file internal.h.

◆ PRIdBDIGIT

#define PRIdBDIGIT   PRI_BDIGIT_PREFIX"d"

Definition at line 460 of file internal.h.

◆ PRIdBDIGIT_DBL

#define PRIdBDIGIT_DBL   PRI_BDIGIT_DBL_PREFIX"d"

Definition at line 469 of file internal.h.

◆ PRIiBDIGIT

#define PRIiBDIGIT   PRI_BDIGIT_PREFIX"i"

Definition at line 461 of file internal.h.

◆ PRIiBDIGIT_DBL

#define PRIiBDIGIT_DBL   PRI_BDIGIT_DBL_PREFIX"i"

Definition at line 470 of file internal.h.

◆ PRIoBDIGIT

#define PRIoBDIGIT   PRI_BDIGIT_PREFIX"o"

Definition at line 462 of file internal.h.

◆ PRIoBDIGIT_DBL

#define PRIoBDIGIT_DBL   PRI_BDIGIT_DBL_PREFIX"o"

Definition at line 471 of file internal.h.

◆ PRIuBDIGIT

#define PRIuBDIGIT   PRI_BDIGIT_PREFIX"u"

Definition at line 463 of file internal.h.

◆ PRIuBDIGIT_DBL

#define PRIuBDIGIT_DBL   PRI_BDIGIT_DBL_PREFIX"u"

Definition at line 472 of file internal.h.

◆ PRIxBDIGIT

#define PRIxBDIGIT   PRI_BDIGIT_PREFIX"x"

Definition at line 464 of file internal.h.

◆ PRIXBDIGIT

#define PRIXBDIGIT   PRI_BDIGIT_PREFIX"X"

Definition at line 465 of file internal.h.

◆ PRIxBDIGIT_DBL

#define PRIxBDIGIT_DBL   PRI_BDIGIT_DBL_PREFIX"x"

Definition at line 473 of file internal.h.

◆ PRIXBDIGIT_DBL

#define PRIXBDIGIT_DBL   PRI_BDIGIT_DBL_PREFIX"X"

Definition at line 474 of file internal.h.

◆ QUOTE

#define QUOTE (   str)    rb_str_quote_unprintable(str)

◆ QUOTE_ID

#define QUOTE_ID (   id)    rb_id_quote_unprintable(id)

◆ rb_cBignum

#define rb_cBignum   rb_cInteger

Definition at line 852 of file internal.h.

Referenced by Init_Bignum().

◆ rb_cFixnum

#define rb_cFixnum   rb_cInteger

Definition at line 851 of file internal.h.

Referenced by Init_Numeric().

◆ rb_float_new

#define rb_float_new (   d)    rb_float_new_inline(d)

◆ rb_float_value

#define rb_float_value (   v)    rb_float_value_inline(v)

Definition at line 1295 of file internal.h.

◆ rb_fstring_lit

#define rb_fstring_lit (   str)    rb_fstring_new((str), rb_strlen_lit(str))

Definition at line 1445 of file internal.h.

◆ rb_fstring_literal

#define rb_fstring_literal (   str)    rb_fstring_lit(str)

Definition at line 1446 of file internal.h.

◆ RB_MAX_GROUPS

#define RB_MAX_GROUPS   (65536)

Definition at line 1356 of file internal.h.

Referenced by rb_group_member().

◆ rb_name_err_raise

#define rb_name_err_raise (   mesg,
  recv,
  name 
)    rb_name_err_raise_str(rb_fstring_cstr(mesg), (recv), (name))

◆ rb_name_err_raise_str

#define rb_name_err_raise_str (   mesg,
  recv,
  name 
)    rb_exc_raise(rb_name_err_new(mesg, recv, name))

◆ RB_NEWOBJ_OF

#define RB_NEWOBJ_OF (   obj,
  type,
  klass,
  flags 
)
Value:
type *(obj) = (type*)(((flags) & FL_WB_PROTECTED) ? \
rb_wb_protected_newobj_of(klass, (flags) & ~FL_WB_PROTECTED) : \
VALUE rb_wb_unprotected_newobj_of(VALUE, VALUE)
Definition: gc.c:1933
#define FL_WB_PROTECTED
Definition: ruby.h:1216

Definition at line 1101 of file internal.h.

◆ RB_OBJ_BUILTIN_TYPE

#define RB_OBJ_BUILTIN_TYPE (   obj)    rb_obj_builtin_type(obj)

Definition at line 1765 of file internal.h.

◆ RB_OBJ_GC_FLAGS_MAX

#define RB_OBJ_GC_FLAGS_MAX   5

Definition at line 1740 of file internal.h.

Referenced by dump_object().

◆ rb_sys_fail_path

#define rb_sys_fail_path (   path)    rb_sys_fail_str(path)

◆ rb_syserr_fail_path

#define rb_syserr_fail_path (   err,
  path 
)    rb_syserr_fail_str((err), (path))

◆ RBASIC_CLEAR_CLASS

#define RBASIC_CLEAR_CLASS (   obj)    memset(&(((struct RBasicRaw *)((VALUE)(obj)))->klass), 0, sizeof(VALUE))

◆ RBASIC_SET_CLASS

#define RBASIC_SET_CLASS (   obj,
  cls 
)

◆ RBASIC_SET_CLASS_RAW

#define RBASIC_SET_CLASS_RAW (   obj,
  cls 
)    memcpy(&((struct RBasicRaw *)((VALUE)(obj)))->klass, &(cls), sizeof(VALUE))

◆ RBIGNUM

#define RBIGNUM (   obj)    (R_CAST(RBignum)(obj))

Definition at line 521 of file internal.h.

Referenced by bignew_1(), and rb_big_realloc().

◆ RCLASS_CALLABLE_M_TBL

#define RCLASS_CALLABLE_M_TBL (   c)    (RCLASS_EXT(c)->callable_m_tbl)

◆ RCLASS_CONST_TBL

#define RCLASS_CONST_TBL (   c)    (RCLASS_EXT(c)->const_tbl)

◆ RCLASS_EXT

#define RCLASS_EXT (   c)    (RCLASS(c)->ptr)

Definition at line 687 of file internal.h.

◆ RCLASS_IV_INDEX_TBL

#define RCLASS_IV_INDEX_TBL (   c)    (RCLASS_EXT(c)->iv_index_tbl)

◆ RCLASS_IV_TBL

#define RCLASS_IV_TBL (   c)    (RCLASS_EXT(c)->iv_tbl)

◆ RCLASS_M_TBL

#define RCLASS_M_TBL (   c)    (RCLASS(c)->m_tbl)

◆ RCLASS_ORIGIN

#define RCLASS_ORIGIN (   c)    (RCLASS_EXT(c)->origin_)

◆ RCLASS_REFINED_CLASS

#define RCLASS_REFINED_CLASS (   c)    (RCLASS_EXT(c)->refined_class)

◆ RCLASS_SERIAL

#define RCLASS_SERIAL (   c)    (RCLASS_EXT(c)->class_serial)

◆ RCOMPLEX

#define RCOMPLEX (   obj)    (R_CAST(RComplex)(obj))

◆ RCOMPLEX_SET_IMAG

#define RCOMPLEX_SET_IMAG (   cmp,
 
)    RB_OBJ_WRITE((cmp), &((struct RComplex *)(cmp))->imag,(i))

Definition at line 552 of file internal.h.

◆ RCOMPLEX_SET_REAL

#define RCOMPLEX_SET_REAL (   cmp,
 
)    RB_OBJ_WRITE((cmp), &((struct RComplex *)(cmp))->real,(r))

Definition at line 551 of file internal.h.

◆ RFLOAT

#define RFLOAT (   obj)    (R_CAST(RFloat)(obj))

Definition at line 538 of file internal.h.

Referenced by negate_lit().

◆ RHASH

#define RHASH (   obj)    (R_CAST(RHash)(obj))

◆ RHASH_IFNONE

#define RHASH_IFNONE (   h)    (RHASH(h)->ifnone)

Definition at line 569 of file internal.h.

◆ RHASH_ITER_LEV

#define RHASH_ITER_LEV (   h)    (RHASH(h)->iter_lev)

Definition at line 568 of file internal.h.

◆ RHASH_SIZE

#define RHASH_SIZE (   h)    (RHASH(h)->ntbl ? RHASH(h)->ntbl->num_entries : (st_index_t)0)

Definition at line 570 of file internal.h.

◆ RHASH_TBL_RAW

#define RHASH_TBL_RAW (   h)    rb_hash_tbl_raw(h)

◆ RICLASS_IS_ORIGIN

#define RICLASS_IS_ORIGIN   FL_USER5

◆ roomof

#define roomof (   x,
 
)    (((x) + (y) - 1) / (y))

◆ ROUND_CALL

#define ROUND_CALL (   mode,
  name,
  args 
)
Value:
ROUND_TO(mode, name##_half_even args, \
name##_half_up args, name##_half_down args)
#define ROUND_TO(mode, even, up, down)
Definition: internal.h:1181
const char * name
Definition: nkf.c:208

Definition at line 1186 of file internal.h.

Referenced by flo_round(), and rb_int_round().

◆ ROUND_DEFAULT

#define ROUND_DEFAULT   RUBY_NUM_ROUND_HALF_UP

Definition at line 1173 of file internal.h.

◆ ROUND_FUNC

#define ROUND_FUNC (   mode,
  name 
)    ROUND_TO(mode, name##_half_even, name##_half_up, name##_half_down)

Definition at line 1184 of file internal.h.

Referenced by nurat_round_n().

◆ ROUND_TO

#define ROUND_TO (   mode,
  even,
  up,
  down 
)
Value:

Definition at line 1181 of file internal.h.

◆ RRATIONAL

#define RRATIONAL (   obj)    (R_CAST(RRational)(obj))

◆ RRATIONAL_SET_DEN

#define RRATIONAL_SET_DEN (   rat,
 
)    RB_OBJ_WRITE((rat), &((struct RRational *)(rat))->den,(d))

Definition at line 531 of file internal.h.

◆ RRATIONAL_SET_NUM

#define RRATIONAL_SET_NUM (   rat,
 
)    RB_OBJ_WRITE((rat), &((struct RRational *)(rat))->num,(n))

Definition at line 530 of file internal.h.

Referenced by negate_lit().

◆ RSTRUCT

#define RSTRUCT (   obj)    (R_CAST(RStruct)(obj))

Definition at line 613 of file internal.h.

Referenced by obj_memsize_of(), rb_struct_const_ptr(), and rb_struct_len().

◆ RSTRUCT_CONST_PTR

#define RSTRUCT_CONST_PTR (   st)    rb_struct_const_ptr(st)

◆ RSTRUCT_EMBED_LEN

#define RSTRUCT_EMBED_LEN (   st)
Value:
(long)((RBASIC(st)->flags >> RSTRUCT_EMBED_LEN_SHIFT) & \
#define RSTRUCT_EMBED_LEN_SHIFT
Definition: internal.h:580
#define RSTRUCT_EMBED_LEN_MASK
Definition: internal.h:579
#define RBASIC(obj)
Definition: ruby.h:1204

Definition at line 604 of file internal.h.

Referenced by rb_struct_len().

◆ RSTRUCT_EMBED_LEN_MASK

#define RSTRUCT_EMBED_LEN_MASK   RSTRUCT_EMBED_LEN_MASK

Definition at line 579 of file internal.h.

Referenced by rb_struct_const_ptr(), and rb_struct_len().

◆ RSTRUCT_EMBED_LEN_MAX

#define RSTRUCT_EMBED_LEN_MAX   RSTRUCT_EMBED_LEN_MAX

Definition at line 578 of file internal.h.

◆ RSTRUCT_EMBED_LEN_SHIFT

#define RSTRUCT_EMBED_LEN_SHIFT   RSTRUCT_EMBED_LEN_SHIFT

Definition at line 580 of file internal.h.

◆ RSTRUCT_GET

#define RSTRUCT_GET (   st,
  idx 
)    (RSTRUCT_CONST_PTR(st)[idx])

Definition at line 612 of file internal.h.

◆ RSTRUCT_LEN

#define RSTRUCT_LEN (   st)    rb_struct_len(st)

Definition at line 607 of file internal.h.

◆ RSTRUCT_LENINT

#define RSTRUCT_LENINT (   st)    rb_long2int(RSTRUCT_LEN(st))

Definition at line 608 of file internal.h.

◆ RSTRUCT_PTR

#define RSTRUCT_PTR (   st)    ((VALUE *)RSTRUCT_CONST_PTR(RB_OBJ_WB_UNPROTECT_FOR(STRUCT, st)))

Definition at line 610 of file internal.h.

◆ RSTRUCT_SET

#define RSTRUCT_SET (   st,
  idx,
 
)    RB_OBJ_WRITE(st, &RSTRUCT_CONST_PTR(st)[idx], (v))

Definition at line 611 of file internal.h.

◆ RUBY_BIT_ROTL

#define RUBY_BIT_ROTL (   v,
 
)    (((v) << (n)) | ((v) >> ((sizeof(v) * 8) - n)))

Definition at line 1225 of file internal.h.

Referenced by rb_float_new_inline().

◆ RUBY_BIT_ROTR

#define RUBY_BIT_ROTR (   v,
 
)    (((v) >> (n)) | ((v) << ((sizeof(v) * 8) - n)))

Definition at line 1226 of file internal.h.

Referenced by rb_float_flonum_value().

◆ RUBY_DTRACE_CREATE_HOOK

#define RUBY_DTRACE_CREATE_HOOK (   name,
  arg 
)    RUBY_DTRACE_HOOK(name##_CREATE, arg)

◆ RUBY_DTRACE_HOOK

#define RUBY_DTRACE_HOOK (   name,
  arg 
)
Value:
do { \
if (UNLIKELY(RUBY_DTRACE_##name##_ENABLED())) { \
int dtrace_line; \
const char *dtrace_file = rb_source_loc(&dtrace_line); \
if (!dtrace_file) dtrace_file = ""; \
RUBY_DTRACE_##name(arg, dtrace_file, dtrace_line); \
} \
} while (0)
const char * rb_source_loc(int *pline)
Definition: vm.c:1291
#define UNLIKELY(x)
Definition: internal.h:27
const char * name
Definition: nkf.c:208

Definition at line 1755 of file internal.h.

Referenced by rb_clear_method_cache_by_class(), rb_f_load(), rb_require_internal(), and setup_exception().

◆ SERIALT2NUM

#define SERIALT2NUM   ULONG2NUM

Definition at line 651 of file internal.h.

◆ SIGNED_INTEGER_MAX

#define SIGNED_INTEGER_MAX (   sint_type)
Value:
(sint_type) \
((((sint_type)1) << (sizeof(sint_type) * CHAR_BIT - 2)) | \
((((sint_type)1) << (sizeof(sint_type) * CHAR_BIT - 2)) - 1))
#define CHAR_BIT
Definition: ruby.h:196

Definition at line 67 of file internal.h.

◆ SIGNED_INTEGER_MIN

#define SIGNED_INTEGER_MIN (   sint_type)    (-SIGNED_INTEGER_MAX(sint_type)-1)

Definition at line 71 of file internal.h.

◆ SIGNED_INTEGER_TYPE_P

#define SIGNED_INTEGER_TYPE_P (   int_type)    (0 > ((int_type)0)-1)

Definition at line 66 of file internal.h.

◆ SIZED_REALLOC_N

#define SIZED_REALLOC_N (   var,
  type,
  n,
  old_n 
)    ((var)=(type*)ruby_sized_xrealloc((char*)(var), (n) * sizeof(type), (old_n) * sizeof(type)))

Definition at line 1093 of file internal.h.

Referenced by ary_resize_capa(), gc_mark_roots(), and rb_ary_resize().

◆ SIZEOF_ACTUAL_BDIGIT

#define SIZEOF_ACTUAL_BDIGIT   SIZEOF_BDIGIT

Definition at line 456 of file internal.h.

◆ SIZEOF_BDIGIT

#define SIZEOF_BDIGIT   SIZEOF_INT

◆ STATIC_ASSERT

#define STATIC_ASSERT (   name,
  expr 
)    typedef int static_assert_##name##_check[1 - 2*!(expr)]

Definition at line 63 of file internal.h.

◆ STR_EMBED_P

#define STR_EMBED_P (   str)    (!FL_TEST_RAW((str), STR_NOEMBED))

◆ STR_NOEMBED

#define STR_NOEMBED   FL_USER1

◆ STR_SHARED

#define STR_SHARED   FL_USER2 /* = ELTS_SHARED */

◆ STR_SHARED_P

#define STR_SHARED_P (   s)    FL_ALL_RAW((s), STR_NOEMBED|ELTS_SHARED)

◆ STRING_P

#define STRING_P (   s)    (RB_TYPE_P((s), T_STRING) && CLASS_OF(s) == rb_cString)

Definition at line 848 of file internal.h.

Referenced by sort_2().

◆ swap16

#define swap16 (   x)    ((uint16_t)((((x)&0xFF)<<8) | (((x)>>8)&0xFF)))

Definition at line 100 of file internal.h.

Referenced by bary_pack(), and bary_unpack_internal().

◆ swap32

#define swap32 (   x)
Value:
((uint32_t)((((x)&0xFF)<<24) \
|(((x)>>24)&0xFF) \
|(((x)&0x0000FF00)<<8) \
|(((x)&0x00FF0000)>>8) ))
unsigned int uint32_t
Definition: sha2.h:101

Definition at line 110 of file internal.h.

Referenced by bary_pack(), and bary_unpack_internal().

◆ THROW_DATA_CONSUMED

#define THROW_DATA_CONSUMED   IMEMO_FL_USER0

Definition at line 777 of file internal.h.

Referenced by THROW_DATA_CONSUMED_P(), and THROW_DATA_CONSUMED_SET().

◆ THROW_DATA_P

#define THROW_DATA_P (   err)    RB_TYPE_P(((VALUE)err), T_IMEMO)

◆ TIMET_MAX_PLUS_ONE

#define TIMET_MAX_PLUS_ONE   (2*(double)(TIMET_MAX/2+1))

Definition at line 81 of file internal.h.

◆ type_roomof

#define type_roomof (   x,
 
)    roomof(sizeof(x), sizeof(y))

Definition at line 839 of file internal.h.

◆ UNLIKELY

#define UNLIKELY (   x)    RB_UNLIKELY(x)

Definition at line 27 of file internal.h.

◆ UNSIGNED_INTEGER_MAX

#define UNSIGNED_INTEGER_MAX (   uint_type)    (~(uint_type)0)

Definition at line 72 of file internal.h.

◆ USE_SYMBOL_GC

#define USE_SYMBOL_GC   1

Definition at line 1321 of file internal.h.

◆ VALGRIND_MAKE_MEM_DEFINED

#define VALGRIND_MAKE_MEM_DEFINED (   p,
 
)    0

Definition at line 46 of file internal.h.

◆ VALGRIND_MAKE_MEM_UNDEFINED

#define VALGRIND_MAKE_MEM_UNDEFINED (   p,
 
)    0

Definition at line 47 of file internal.h.

◆ WARN_UNUSED_RESULT

#define WARN_UNUSED_RESULT (   x )    x

Definition at line 34 of file internal.h.

Typedef Documentation

◆ rb_check_funcall_hook

typedef void rb_check_funcall_hook(int, VALUE, ID, int, const VALUE *, VALUE)

Definition at line 1605 of file internal.h.

◆ rb_classext_t

Definition at line 673 of file internal.h.

◆ rb_serial_t

typedef unsigned long rb_serial_t

Definition at line 650 of file internal.h.

◆ rb_subclass_entry_t

Definition at line 636 of file internal.h.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
RSTRUCT_EMBED_LEN_MAX 
RSTRUCT_EMBED_LEN_MASK 
RSTRUCT_EMBED_LEN_SHIFT 
RSTRUCT_ENUM_END 

Definition at line 581 of file internal.h.

◆ anonymous enum

anonymous enum
Enumerator
cmp_opt_Fixnum 
cmp_opt_String 
cmp_optimizable_count 

Definition at line 855 of file internal.h.

◆ imemo_type

enum imemo_type
Enumerator
imemo_env 
imemo_cref 
imemo_svar 
imemo_throw_data 
imemo_ifunc 
imemo_memo 
imemo_ment 
imemo_iseq 
imemo_mask 

Definition at line 737 of file internal.h.

◆ ruby_num_rounding_mode

Enumerator
RUBY_NUM_ROUND_HALF_UP 
RUBY_NUM_ROUND_HALF_EVEN 
RUBY_NUM_ROUND_HALF_DOWN 
RUBY_NUM_ROUND_DEFAULT 

Definition at line 1175 of file internal.h.

Function Documentation

◆ CONSTFUNC() [1/4]

CONSTFUNC ( const char *  rb_insns_nameint i)

◆ CONSTFUNC() [2/4]

CONSTFUNC ( void   rb_gc_mark_encodingsvoid)

◆ CONSTFUNC() [3/4]

CONSTFUNC ( VALUE   rb_obj_equalVALUE obj1, VALUE obj2)

◆ CONSTFUNC() [4/4]

CONSTFUNC ( VALUE   rb_obj_notVALUE obj)

◆ imemo_type()

static enum imemo_type imemo_type ( VALUE  imemo)
inlinestatic

Definition at line 750 of file internal.h.

References FL_USHIFT, imemo_mask, and RBASIC.

◆ Init_BareVM()

void Init_BareVM ( void  )

◆ Init_enc()

void Init_enc ( void  )

Definition at line 5 of file dmyenc.c.

References rb_encdb_alias(), rb_encdb_declare(), and require.

Referenced by init_libraries_internal(), and process_options().

◆ Init_enc_set_filesystem_encoding()

int Init_enc_set_filesystem_encoding ( void  )

◆ Init_eval_method()

void Init_eval_method ( void  )

◆ Init_ext()

void Init_ext ( void  )

Definition at line 2 of file dmyext.c.

Referenced by init_libraries_internal(), and process_options().

◆ Init_File()

void Init_File ( void  )

Definition at line 5953 of file file.c.

References define_filetest_function(), INT2FIX, LOCK_EX, LOCK_NB, LOCK_SH, LOCK_UN, O_BINARY, O_NONBLOCK, O_SHARE_DELETE, PATH_SEP, Qnil, rb_cFile, rb_cIO, rb_cObject, rb_cStat, rb_define_alloc_func(), rb_define_class(), rb_define_class_under(), rb_define_const(), rb_define_global_function(), rb_define_method(), rb_define_module(), rb_define_module_under(), rb_define_singleton_method(), rb_f_test(), rb_file_atime(), rb_file_birthtime, rb_file_blockdev_p(), rb_file_chardev_p(), rb_file_chmod(), rb_file_chown(), rb_file_ctime(), rb_file_directory_p(), rb_file_executable_p(), rb_file_executable_real_p(), rb_file_exist_p(), rb_file_exists_p(), rb_file_file_p(), rb_file_flock(), rb_file_grpowned_p(), rb_file_identical_p(), rb_file_lstat(), rb_file_mtime(), rb_file_owned_p(), rb_file_path(), rb_file_pipe_p(), rb_file_readable_p(), rb_file_readable_real_p(), rb_file_s_absolute_path(), rb_file_s_atime(), rb_file_s_basename(), rb_file_s_birthtime, rb_file_s_chmod(), rb_file_s_chown(), rb_file_s_ctime(), rb_file_s_dirname(), rb_file_s_expand_path(), rb_file_s_extname(), rb_file_s_ftype(), rb_file_s_join(), rb_file_s_lchmod, rb_file_s_lchown, rb_file_s_link, rb_file_s_lstat(), rb_file_s_mkfifo, rb_file_s_mtime(), rb_file_s_path(), rb_file_s_readlink, rb_file_s_realdirpath(), rb_file_s_realpath(), rb_file_s_rename(), rb_file_s_size(), rb_file_s_split(), rb_file_s_stat(), rb_file_s_symlink, rb_file_s_truncate, rb_file_s_umask(), rb_file_s_unlink(), rb_file_s_utime(), rb_file_sgid_p(), rb_file_size(), rb_file_size_p(), rb_file_socket_p(), rb_file_sticky_p(), rb_file_suid_p(), rb_file_symlink_p(), rb_file_truncate, rb_file_world_readable_p(), rb_file_world_writable_p(), rb_file_writable_p(), rb_file_writable_real_p(), rb_file_zero_p(), rb_include_module(), rb_io_stat(), rb_mComparable, rb_mFileTest, rb_obj_freeze(), rb_stat_atime(), rb_stat_b(), rb_stat_birthtime, rb_stat_blksize(), rb_stat_blocks(), rb_stat_c(), rb_stat_cmp(), rb_stat_ctime(), rb_stat_d(), rb_stat_dev(), rb_stat_dev_major(), rb_stat_dev_minor(), rb_stat_f(), rb_stat_ftype(), rb_stat_gid(), rb_stat_grpowned(), rb_stat_init(), rb_stat_init_copy(), rb_stat_ino(), rb_stat_inspect(), rb_stat_l(), rb_stat_mode(), rb_stat_mtime(), rb_stat_nlink(), rb_stat_owned(), rb_stat_p(), rb_stat_r(), rb_stat_R(), rb_stat_rdev(), rb_stat_rdev_major(), rb_stat_rdev_minor(), rb_stat_S(), rb_stat_s(), rb_stat_s_alloc(), rb_stat_sgid(), rb_stat_size(), rb_stat_sticky(), rb_stat_suid(), rb_stat_uid(), rb_stat_w(), rb_stat_W(), rb_stat_wr(), rb_stat_ww(), rb_stat_x(), rb_stat_X(), rb_stat_z(), rb_str_new2, and rb_usascii_str_new2.

Referenced by Init_IO().

◆ Init_heap()

void Init_heap ( void  )

◆ Init_native_thread()

void Init_native_thread ( void  )

Referenced by Init_BareVM().

◆ Init_newline()

void Init_newline ( void  )

Referenced by InitVM_transcode().

◆ Init_prelude()

void Init_prelude ( void  )

Referenced by ruby_init_prelude().

◆ Init_vm_backtrace()

void Init_vm_backtrace ( void  )

◆ Init_vm_eval()

void Init_vm_eval ( void  )

◆ Init_vm_objects()

void Init_vm_objects ( void  )

◆ nlz_int()

static unsigned int nlz_int ( unsigned int  x)
inlinestatic

Definition at line 137 of file internal.h.

References CHAR_BIT.

Referenced by nlz(), and nlz_intptr().

◆ nlz_intptr()

static unsigned int nlz_intptr ( uintptr_t  x)
inlinestatic

Definition at line 246 of file internal.h.

References nlz_int().

Referenced by search_nonascii().

◆ nlz_long()

static unsigned int nlz_long ( unsigned long  x)
inlinestatic

Definition at line 167 of file internal.h.

References CHAR_BIT.

Referenced by nlz(), and random_ulong_limited().

◆ NORETURN() [1/5]

NORETURN ( void   rb_async_bug_errnoconst char *, int)

◆ NORETURN() [2/5]

NORETURN ( void   ruby_only_for_internal_useconst char *)

◆ NORETURN() [3/5]

NORETURN ( void   rb_load_failVALUE, const char *)

◆ NORETURN() [4/5]

NORETURN ( void   rb_undefined_allocVALUE klass)

◆ NORETURN() [5/5]

NORETURN ( void   rb_unexpected_typeVALUE, int)

◆ ntz_int32()

static int ntz_int32 ( uint32_t  x)
inlinestatic

Definition at line 295 of file internal.h.

References rb_popcount32().

Referenced by ntz_intptr().

◆ ntz_int64()

static int ntz_int64 ( uint64_t  x)
inlinestatic

Definition at line 305 of file internal.h.

References rb_popcount64().

Referenced by ntz_intptr().

◆ ntz_intptr()

static int ntz_intptr ( uintptr_t  x)
inlinestatic

Definition at line 315 of file internal.h.

References ntz_int32(), and ntz_int64().

Referenced by search_nonascii().

◆ PRINTF_ARGS() [1/3]

PRINTF_ARGS ( void   ruby_debug_printfconst char *,...,
,
 
)

◆ PRINTF_ARGS() [2/3]

PRINTF_ARGS ( void   rb_compile_error_strVALUE file, int line, void *enc, const char *fmt,...,
,
 
)

◆ PRINTF_ARGS() [3/3]

PRINTF_ARGS ( void   rb_enc_warnrb_encoding *enc, const char *fmt,...,
,
 
)

◆ PUREFUNC() [1/4]

PUREFUNC ( int   rb_data_is_encodingVALUE obj)

◆ PUREFUNC() [2/4]

PUREFUNC ( int   rb_is_const_symVALUE sym)

◆ PUREFUNC() [3/4]

PUREFUNC ( VALUE   rb_vm_top_selfvoid)

◆ PUREFUNC() [4/4]

PUREFUNC ( st_table rb_vm_fstring_tablevoid)

◆ rb_ary_at()

VALUE rb_ary_at ( VALUE  ,
VALUE   
)

Definition at line 1313 of file array.c.

References NUM2LONG, and rb_ary_entry().

Referenced by Init_Array(), rb_ary_dig(), and rb_obj_dig().

◆ rb_ary_delete_same()

void rb_ary_delete_same ( VALUE  ,
VALUE   
)

Definition at line 3022 of file array.c.

References ary_resize_smaller(), RARRAY_AREF, RARRAY_LEN, and rb_ary_store().

Referenced by rb_obj_info_dump().

◆ rb_ary_last()

VALUE rb_ary_last ( int  ,
const VALUE ,
VALUE   
)

◆ rb_ary_memsize()

size_t rb_ary_memsize ( VALUE  )

Definition at line 555 of file array.c.

References ARY_OWNS_HEAP_P, and RARRAY.

Referenced by obj_memsize_of().

◆ rb_ary_set_len()

void rb_ary_set_len ( VALUE  ,
long   
)

◆ rb_ary_tmp_new_fill()

VALUE rb_ary_tmp_new_fill ( long  capa)

Definition at line 538 of file array.c.

References ary_memfill(), ary_new(), ARY_SET_LEN, and Qnil.

Referenced by coverage().

◆ rb_attr_delete()

VALUE rb_attr_delete ( VALUE  ,
ID   
)

Definition at line 1315 of file variable.c.

References Qnil, and rb_ivar_delete().

◆ rb_autoload_str()

void rb_autoload_str ( VALUE  mod,
ID  id,
VALUE  file 
)

◆ rb_backref_set_string()

void rb_backref_set_string ( VALUE  string,
long  pos,
long  len 
)

◆ rb_backtrace_p()

int rb_backtrace_p ( VALUE  obj)

Definition at line 410 of file vm_backtrace.c.

References rb_typeddata_is_kind_of().

Referenced by exc_backtrace(), rb_check_backtrace(), and set_backtrace().

◆ rb_backtrace_print_as_bugreport()

void rb_backtrace_print_as_bugreport ( void  )

◆ rb_backtrace_print_to()

void rb_backtrace_print_to ( VALUE  output)

◆ rb_backtrace_to_location_ary()

VALUE rb_backtrace_to_location_ary ( VALUE  obj)

◆ rb_backtrace_to_str_ary()

VALUE rb_backtrace_to_str_ary ( VALUE  obj)

◆ rb_big2str_generic()

VALUE rb_big2str_generic ( VALUE  x,
int  base 
)

◆ rb_big2str_poweroftwo()

VALUE rb_big2str_poweroftwo ( VALUE  x,
int  base 
)

Definition at line 4871 of file bignum.c.

References big2str_base_poweroftwo().

◆ rb_big_abs()

VALUE rb_big_abs ( VALUE  x)

Definition at line 6685 of file bignum.c.

References BIGNUM_NEGATIVE_P, BIGNUM_SET_POSITIVE_SIGN, and rb_big_clone().

Referenced by rb_int_abs().

◆ rb_big_aref()

VALUE rb_big_aref ( VALUE  x,
VALUE  y 
)

◆ rb_big_bit_length()

VALUE rb_big_bit_length ( VALUE  big)

◆ rb_big_comp()

VALUE rb_big_comp ( VALUE  x)

◆ rb_big_divrem_normal()

VALUE rb_big_divrem_normal ( VALUE  x,
VALUE  y 
)

◆ rb_big_even_p()

VALUE rb_big_even_p ( VALUE  )

Definition at line 6763 of file bignum.c.

References BDIGITS, BIGNUM_LEN, Qfalse, and Qtrue.

Referenced by int_even_p().

◆ rb_big_fdiv_double()

double rb_big_fdiv_double ( VALUE  x,
VALUE  y 
)

◆ rb_big_ge()

VALUE rb_big_ge ( VALUE  x,
VALUE  y 
)

Definition at line 5422 of file bignum.c.

References big_op(), and big_op_ge.

Referenced by rb_int_ge().

◆ rb_big_gt()

VALUE rb_big_gt ( VALUE  x,
VALUE  y 
)

Definition at line 5416 of file bignum.c.

References big_op(), and big_op_gt.

Referenced by rb_int_gt().

◆ rb_big_hash()

VALUE rb_big_hash ( VALUE  )

Definition at line 6649 of file bignum.c.

References BDIGIT, BDIGITS, BIGNUM_LEN, BIGNUM_SIGN, hash(), rb_memhash(), and ST2FIX.

Referenced by any_hash().

◆ rb_big_le()

VALUE rb_big_le ( VALUE  x,
VALUE  y 
)

Definition at line 5434 of file bignum.c.

References big_op(), and big_op_le.

Referenced by int_le().

◆ rb_big_lt()

VALUE rb_big_lt ( VALUE  x,
VALUE  y 
)

Definition at line 5428 of file bignum.c.

References big_op(), and big_op_lt.

Referenced by int_lt().

◆ rb_big_mul_balance()

VALUE rb_big_mul_balance ( VALUE  x,
VALUE  y 
)

◆ rb_big_mul_karatsuba()

VALUE rb_big_mul_karatsuba ( VALUE  x,
VALUE  y 
)

◆ rb_big_mul_normal()

VALUE rb_big_mul_normal ( VALUE  x,
VALUE  y 
)

Definition at line 1540 of file bignum.c.

References bary_mul_normal(), BDIGITS, bignew, BIGNUM_LEN, BIGNUM_SIGN, and RB_GC_GUARD.

◆ rb_big_mul_toom3()

VALUE rb_big_mul_toom3 ( VALUE  x,
VALUE  y 
)

◆ rb_big_odd_p()

VALUE rb_big_odd_p ( VALUE  )

Definition at line 6754 of file bignum.c.

References BDIGITS, BIGNUM_LEN, Qfalse, and Qtrue.

Referenced by int_odd_p().

◆ rb_big_remainder()

VALUE rb_big_remainder ( VALUE  x,
VALUE  y 
)

◆ rb_big_size()

size_t rb_big_size ( VALUE  )

Definition at line 6701 of file bignum.c.

References BIGSIZE.

Referenced by int_round_zero_p(), and rb_big_size_m().

◆ rb_big_size_m()

VALUE rb_big_size_m ( VALUE  big)

Definition at line 6707 of file bignum.c.

References rb_big_size(), and SIZET2NUM.

Referenced by int_size().

◆ rb_big_sq_fast()

VALUE rb_big_sq_fast ( VALUE  x)

Definition at line 1609 of file bignum.c.

References bary_sq_fast(), BDIGITS, bignew, BIGNUM_LEN, and RB_GC_GUARD.

◆ rb_big_uminus()

VALUE rb_big_uminus ( VALUE  x)

Definition at line 5481 of file bignum.c.

References bignorm(), BIGNUM_NEGATE, and rb_big_clone().

Referenced by rand_int(), rb_int_uminus(), and rb_str_format().

◆ rb_block_arity()

int rb_block_arity ( void  )

◆ rb_block_min_max_arity()

int rb_block_min_max_arity ( int *  max)

◆ rb_bug_reporter_add()

int rb_bug_reporter_add ( void(*)(FILE *, void *)  func,
void *  data 
)

◆ rb_builtin_class_name()

const char* rb_builtin_class_name ( VALUE  x)

◆ rb_builtin_type_name()

const char* rb_builtin_type_name ( int  t)

Definition at line 609 of file error.c.

References name, and numberof.

Referenced by compile_dstr_fragments(), unexpected_type(), and w_object().

◆ rb_call_end_proc()

void rb_call_end_proc ( VALUE  data)

Definition at line 11 of file eval_jump.c.

References rb_ary_new(), and rb_proc_call().

Referenced by m_core_set_postexe(), and rb_f_at_exit().

◆ rb_call_inits()

void rb_call_inits ( void  )

Definition at line 17 of file inits.c.

References CALL, sym, and version.

Referenced by ruby_setup().

◆ rb_catch_protect()

VALUE rb_catch_protect ( VALUE  t,
rb_block_call_func func,
VALUE  data,
int *  stateptr 
)

Definition at line 2041 of file vm_eval.c.

References GET_THREAD, and vm_catch_protect().

Referenced by exec_recursive().

◆ rb_check_backtrace()

VALUE rb_check_backtrace ( VALUE  )

◆ rb_check_block_call()

VALUE rb_check_block_call ( VALUE  ,
ID  ,
int  ,
const VALUE ,
rb_block_call_func_t  ,
VALUE   
)

Referenced by take_items().

◆ rb_check_funcall_default()

VALUE rb_check_funcall_default ( VALUE  ,
ID  ,
int  ,
const VALUE ,
VALUE   
)

◆ rb_check_funcall_with_hook()

VALUE rb_check_funcall_with_hook ( VALUE  recv,
ID  mid,
int  argc,
const VALUE argv,
rb_check_funcall_hook hook,
VALUE  arg 
)

◆ rb_class_ivar_set()

int rb_class_ivar_set ( VALUE  klass,
ID  vid,
VALUE  value 
)

◆ rb_class_search_ancestor()

VALUE rb_class_search_ancestor ( VALUE  klass,
VALUE  super 
)

Definition at line 710 of file object.c.

References class_or_module_required(), class_search_ancestor(), and RCLASS_ORIGIN.

Referenced by umethod_bind().

◆ rb_clear_trace_func()

void rb_clear_trace_func ( void  )

◆ rb_complex_abs()

VALUE rb_complex_abs ( VALUE  x)

Definition at line 1464 of file complex.c.

References nucomp_abs().

Referenced by rb_math_sqrt().

◆ rb_complex_mul()

VALUE rb_complex_mul ( VALUE  ,
VALUE   
)

◆ rb_complex_plus()

VALUE rb_complex_plus ( VALUE  ,
VALUE   
)

◆ rb_complex_sqrt()

VALUE rb_complex_sqrt ( VALUE  x)

Referenced by m_sin().

◆ rb_const_missing()

VALUE rb_const_missing ( VALUE  klass,
VALUE  name 
)

Definition at line 1794 of file variable.c.

References rb_funcallv, rb_intern, and rb_vm_inc_const_missing_count().

Referenced by rb_const_get_0(), and rb_mod_const_get().

◆ rb_copy_wb_protected_attribute()

void rb_copy_wb_protected_attribute ( VALUE  dest,
VALUE  obj 
)

◆ rb_cstr_parse_inum()

VALUE rb_cstr_parse_inum ( const char *  str,
ssize_t  len,
char **  endp,
int  base 
)

◆ rb_cstr_to_rat()

VALUE rb_cstr_to_rat ( const char *  ,
int   
)

Definition at line 2560 of file rational.c.

References parse_rat(), rb_eFloatDomainError, RB_FLOAT_TYPE_P, and rb_raise().

Referenced by str2num().

◆ rb_current_realfilepath()

VALUE rb_current_realfilepath ( void  )

◆ rb_dbl_hash()

VALUE rb_dbl_hash ( double  d)

Definition at line 1442 of file numeric.c.

References LONG2FIX, and rb_dbl_long_hash().

Referenced by flo_hash().

◆ rb_dbl_long_hash()

long rb_dbl_long_hash ( double  d)

Definition at line 149 of file hash.c.

References rb_hash_start(), rb_memhash(), and rb_objid_hash().

Referenced by any_hash(), and rb_dbl_hash().

◆ rb_default_home_dir()

VALUE rb_default_home_dir ( VALUE  result)

◆ rb_deprecate_constant()

void rb_deprecate_constant ( VALUE  mod,
const char *  name 
)

◆ rb_divert_reserved_fd()

int rb_divert_reserved_fd ( int  fd)

◆ rb_dvar_defined()

int rb_dvar_defined ( ID  ,
const struct rb_block  
)

◆ rb_econv_memsize()

size_t rb_econv_memsize ( rb_econv_t )

◆ rb_enc_check_str()

rb_encoding* rb_enc_check_str ( VALUE  str1,
VALUE  str2 
)

◆ rb_enc_get_from_index()

rb_encoding* rb_enc_get_from_index ( int  index)

Definition at line 628 of file encoding.c.

References must_encindex().

Referenced by get_actual_encoding(), and str_new_static().

◆ rb_enc_set_base()

void rb_enc_set_base ( const char *  name,
const char *  orig 
)

Definition at line 389 of file encoding.c.

References rb_enc_from_index(), rb_enc_registered(), and set_base_encoding().

◆ rb_enc_set_dummy()

int rb_enc_set_dummy ( int  index)

Definition at line 400 of file encoding.c.

References rb_encoding_entry::enc, ENC_SET_DUMMY, and enc_table.

◆ rb_encdb_alias()

int rb_encdb_alias ( const char *  alias,
const char *  orig 
)

Definition at line 572 of file encoding.c.

◆ rb_encdb_declare()

void rb_encdb_declare ( const char *  name)

Definition at line 357 of file encoding.c.

◆ rb_encdb_dummy()

int rb_encdb_dummy ( const char *  name)

◆ rb_encdb_replicate()

int rb_encdb_replicate ( const char *  alias,
const char *  orig 
)

◆ rb_encdb_set_unicode()

void rb_encdb_set_unicode ( int  index)

Definition at line 583 of file encoding.c.

References ONIGENC_FLAG_UNICODE, and rb_enc_from_index().

◆ rb_equal_opt()

VALUE rb_equal_opt ( VALUE  obj1,
VALUE  obj2 
)

◆ rb_exec_async_signal_safe()

int rb_exec_async_signal_safe ( const struct rb_execarg e,
char *  errmsg,
size_t  errmsg_buflen 
)

◆ rb_execarg_addopt()

int rb_execarg_addopt ( VALUE  execarg_obj,
VALUE  key,
VALUE  val 
)

◆ rb_execarg_extract_options()

VALUE rb_execarg_extract_options ( VALUE  execarg_obj,
VALUE  opthash 
)

Definition at line 1928 of file process.c.

References check_exec_options_i_extract(), Qnil, rb_hash_tbl_raw(), RHASH_EMPTY_P, st_data_t, and st_foreach.

Referenced by rb_io_s_popen().

◆ rb_execarg_get()

struct rb_execarg* rb_execarg_get ( VALUE  execarg_obj)

◆ rb_execarg_init()

VALUE rb_execarg_init ( int  argc,
const VALUE argv,
int  accept_shell,
VALUE  execarg_obj 
)

◆ rb_execarg_new()

VALUE rb_execarg_new ( int  argc,
const VALUE argv,
int  accept_shell 
)

◆ rb_execarg_parent_end()

void rb_execarg_parent_end ( VALUE  execarg_obj)

Definition at line 2496 of file process.c.

References execarg_parent_end(), and RB_GC_GUARD.

Referenced by establishShell(), pipe_open(), and rb_execarg_parent_start().

◆ rb_execarg_parent_start()

void rb_execarg_parent_start ( VALUE  execarg_obj)

◆ rb_execarg_run_options()

int rb_execarg_run_options ( const struct rb_execarg e,
struct rb_execarg s,
char *  errmsg,
size_t  errmsg_buflen 
)

◆ rb_execarg_setenv()

void rb_execarg_setenv ( VALUE  execarg_obj,
VALUE  env 
)

◆ rb_f_send()

VALUE rb_f_send ( int  argc,
VALUE argv,
VALUE  recv 
)

Definition at line 980 of file vm_eval.c.

References CALL_FCALL, and send_internal().

Referenced by Init_vm_eval().

◆ rb_fiber_reset_root_local_storage()

void rb_fiber_reset_root_local_storage ( VALUE  )

◆ rb_file_const()

void rb_file_const ( const char *  ,
VALUE   
)

Definition at line 5585 of file file.c.

References rb_define_const().

Referenced by Init_Dir().

◆ rb_file_expand_path_fast()

VALUE rb_file_expand_path_fast ( VALUE  ,
VALUE   
)

Definition at line 3693 of file file.c.

References expand_path, and EXPAND_PATH_BUFFER.

Referenced by rb_construct_expanded_load_path(), and rb_feature_provided().

◆ rb_file_expand_path_internal()

VALUE rb_file_expand_path_internal ( VALUE  ,
VALUE  ,
int  ,
int  ,
VALUE   
)

◆ rb_file_load_ok()

int rb_file_load_ok ( const char *  )

◆ rb_fix_div_fix()

static VALUE rb_fix_div_fix ( VALUE  x,
VALUE  y 
)
inlinestatic

Definition at line 385 of file internal.h.

References div, NULL, and rb_fix_divmod_fix().

Referenced by fix_divide().

◆ rb_fix_divmod_fix()

static void rb_fix_divmod_fix ( VALUE  a,
VALUE  b,
VALUE divp,
VALUE modp 
)
inlinestatic

Definition at line 357 of file internal.h.

References div, FIX2LONG, FIXNUM_MIN, LONG2FIX, LONG2NUM, and mod.

Referenced by divmodv(), fix_divmod(), rb_fix_div_fix(), and rb_fix_mod_fix().

◆ rb_fix_mod_fix()

static VALUE rb_fix_mod_fix ( VALUE  x,
VALUE  y 
)
inlinestatic

Definition at line 396 of file internal.h.

References mod, NULL, and rb_fix_divmod_fix().

Referenced by fix_mod(), and mod().

◆ rb_fix_mul_fix()

static VALUE rb_fix_mul_fix ( VALUE  x,
VALUE  y 
)
inlinestatic

Definition at line 336 of file internal.h.

References FIX2LONG, LONG2FIX, MUL_OVERFLOW_FIXNUM_P, rb_big_mul(), and rb_int2big().

Referenced by fix_mul(), and mul().

◆ rb_fix_plus()

VALUE rb_fix_plus ( VALUE  x,
VALUE  y 
)

Definition at line 3508 of file numeric.c.

References fix_plus().

Referenced by ary_inject_op(), enum_sum(), rb_ary_sum(), and sum_iter().

◆ rb_float_abs()

VALUE rb_float_abs ( VALUE  flt)

Definition at line 1704 of file numeric.c.

References DBL2NUM, RFLOAT_VALUE, and val.

Referenced by Init_Numeric(), and numeric_polar().

◆ rb_float_flonum_value()

static double rb_float_flonum_value ( VALUE  v)
inlinestatic

Definition at line 1230 of file internal.h.

References RUBY_BIT_ROTR.

Referenced by rb_float_value_inline(), rb_num2dbl(), and rb_num_to_dbl().

◆ rb_float_gt()

VALUE rb_float_gt ( VALUE  x,
VALUE  y 
)

◆ rb_float_new_inline()

static VALUE rb_float_new_inline ( double  d)
inlinestatic

Definition at line 1266 of file internal.h.

References rb_float_new_in_heap(), and RUBY_BIT_ROTL.

Referenced by rb_float_new().

◆ rb_float_noflonum_value()

static double rb_float_noflonum_value ( VALUE  v)
inlinestatic

Definition at line 1251 of file internal.h.

Referenced by rb_float_value_inline(), rb_num2dbl(), and rb_num_to_dbl().

◆ rb_float_pow()

VALUE rb_float_pow ( VALUE  x,
VALUE  y 
)

◆ rb_float_uminus()

VALUE rb_float_uminus ( VALUE  num)

Definition at line 1057 of file numeric.c.

References DBL2NUM, and RFLOAT_VALUE.

Referenced by Init_Numeric().

◆ rb_float_value_inline()

static double rb_float_value_inline ( VALUE  v)
inlinestatic

Definition at line 1257 of file internal.h.

References FLONUM_P, rb_float_flonum_value(), and rb_float_noflonum_value().

Referenced by rb_float_value().

◆ rb_fork_async_signal_safe()

rb_pid_t rb_fork_async_signal_safe ( int *  status,
int(*)(void *, char *, size_t)  chfunc,
void *  charg,
VALUE  fds,
char *  errmsg,
size_t  errmsg_buflen 
)

◆ rb_fork_ruby()

rb_pid_t rb_fork_ruby ( int *  status)

◆ rb_fstring()

VALUE rb_fstring ( VALUE  )

◆ rb_fstring_cstr()

VALUE rb_fstring_cstr ( const char *  str)

◆ rb_fstring_new()

VALUE rb_fstring_new ( const char *  ptr,
long  len 
)

◆ rb_func_lambda_new()

VALUE rb_func_lambda_new ( rb_block_call_func_t  func,
VALUE  val,
int  min_argc,
int  max_argc 
)

Definition at line 683 of file proc.c.

References cfunc_proc_new(), rb_cProc, and rb_vm_ifunc_new().

◆ rb_func_proc_new()

VALUE rb_func_proc_new ( rb_block_call_func_t  func,
VALUE  val 
)

Definition at line 676 of file proc.c.

References cfunc_proc_new(), rb_cProc, and rb_vm_ifunc_proc_new().

Referenced by rb_hash_to_proc(), and vm_caller_setup_arg_block().

◆ rb_gc_for_fd()

int rb_gc_for_fd ( int  err)

◆ rb_gc_free_dsymbol()

void rb_gc_free_dsymbol ( VALUE  )

Definition at line 629 of file symbol.c.

References symbols::dsymbol_fstr_hash, global_symbols, rb_hash_delete_entry(), RSYMBOL, and unregister_sym().

Referenced by obj_free().

◆ rb_gc_mark_global_tbl()

void rb_gc_mark_global_tbl ( void  )

Definition at line 593 of file variable.c.

References mark_global_entry(), rb_global_tbl, and rb_id_table_foreach_values().

Referenced by gc_mark_roots().

◆ rb_gc_mark_values()

void rb_gc_mark_values ( long  n,
const VALUE values 
)

Definition at line 4024 of file gc.c.

References gc_mark_values(), and rb_objspace.

Referenced by rb_thread_mark().

◆ rb_gc_resurrect()

void rb_gc_resurrect ( VALUE  ptr)

◆ rb_gc_verify_internal_consistency()

void rb_gc_verify_internal_consistency ( void  )

Definition at line 5298 of file gc.c.

References gc_verify_internal_consistency(), and Qnil.

Referenced by vm_pop_frame().

◆ rb_gc_writebarrier_remember()

void rb_gc_writebarrier_remember ( VALUE  obj)

◆ rb_gcd()

VALUE rb_gcd ( VALUE  x,
VALUE  y 
)

Definition at line 1850 of file rational.c.

References f_gcd(), and nurat_int_value().

Referenced by Init_Rational(), and rb_int_fdiv_double().

◆ rb_gcd_normal()

VALUE rb_gcd_normal ( VALUE  self,
VALUE  other 
)

Definition at line 335 of file rational.c.

References f_gcd_normal().

◆ rb_generic_ivar_memsize()

size_t rb_generic_ivar_memsize ( VALUE  )

Definition at line 1200 of file variable.c.

References gen_ivtbl_bytes(), gen_ivtbl_get(), and gen_ivtbl::numiv.

Referenced by obj_memsize_of().

◆ rb_get_backtrace()

VALUE rb_get_backtrace ( VALUE  info)

◆ rb_get_coverages()

VALUE rb_get_coverages ( void  )

◆ rb_get_expanded_load_path()

VALUE rb_get_expanded_load_path ( void  )

◆ rb_get_load_path()

VALUE rb_get_load_path ( void  )

Definition at line 30 of file load.c.

References GET_VM.

◆ rb_get_next_signal()

int rb_get_next_signal ( void  )

Definition at line 739 of file signal.c.

References ATOMIC_DEC, RUBY_NSIG, and signal_buff.

Referenced by rb_threadptr_execute_interrupts().

◆ rb_get_path_check_convert()

VALUE rb_get_path_check_convert ( VALUE  ,
VALUE  ,
int   
)

◆ rb_get_path_check_to_string()

VALUE rb_get_path_check_to_string ( VALUE  ,
int   
)

◆ rb_global_entry()

◆ rb_gvar_defined()

VALUE rb_gvar_defined ( struct rb_global_entry )

Definition at line 859 of file variable.c.

References rb_global_variable::getter, Qfalse, Qtrue, rb_gvar_undef_getter(), and rb_global_entry::var.

Referenced by vm_defined().

◆ rb_gvar_get()

VALUE rb_gvar_get ( struct rb_global_entry )

◆ rb_gvar_set()

VALUE rb_gvar_set ( struct rb_global_entry ,
VALUE   
)

◆ rb_hash_add_new_element()

int rb_hash_add_new_element ( VALUE  hash,
VALUE  key,
VALUE  val 
)

Definition at line 3034 of file hash.c.

References add_new_i(), hash(), rb_hash_tbl_raw(), st_update(), and val.

Referenced by ary_add_hash(), ary_add_hash_by(), lazy_uniq_i(), uniq_func(), and uniq_iter().

◆ rb_hash_compare_by_id_p()

VALUE rb_hash_compare_by_id_p ( VALUE  hash)

Definition at line 2797 of file hash.c.

References Qfalse, Qtrue, and RHASH.

Referenced by Init_Hash(), and rb_hash_compare_by_id().

◆ rb_hash_default_value()

VALUE rb_hash_default_value ( VALUE  hash,
VALUE  key 
)

◆ rb_hash_delete_entry()

VALUE rb_hash_delete_entry ( VALUE  hash,
VALUE  key 
)

◆ rb_hash_has_key()

VALUE rb_hash_has_key ( VALUE  hash,
VALUE  key 
)

Definition at line 2105 of file hash.c.

References Qfalse, Qtrue, RHASH, and st_lookup.

Referenced by Init_Hash().

◆ rb_hash_keys()

VALUE rb_hash_keys ( VALUE  hash)

◆ rb_hash_proc()

st_index_t rb_hash_proc ( st_index_t  hash,
VALUE  proc 
)

◆ rb_hash_rehash()

VALUE rb_hash_rehash ( VALUE  hash)

◆ rb_hash_set_default_proc()

VALUE rb_hash_set_default_proc ( VALUE  hash,
VALUE  proc 
)

◆ rb_hash_tbl_raw()

struct st_table* rb_hash_tbl_raw ( VALUE  hash)

◆ rb_hash_values()

VALUE rb_hash_values ( VALUE  hash)

◆ rb_home_dir_of()

VALUE rb_home_dir_of ( VALUE  user,
VALUE  result 
)

◆ rb_id_attrget()

ID rb_id_attrget ( ID  id)

Definition at line 158 of file symbol.c.

References attrsetname_to_attr(), and rb_id2str().

◆ rb_id_encoding()

ID rb_id_encoding ( void  )

Definition at line 753 of file encoding.c.

References CONST_ID, and id_encoding.

Referenced by dir_initialize(), enc_get_index_str(), enc_set_index(), Init_IO(), rb_str_init(), and w_encoding().

◆ rb_id_quote_unprintable()

VALUE rb_id_quote_unprintable ( ID  )

Definition at line 9640 of file string.c.

References rb_id2str, and rb_str_quote_unprintable().

◆ rb_ident_hash_new()

VALUE rb_ident_hash_new ( void  )

◆ rb_imemo_new()

VALUE rb_imemo_new ( enum imemo_type  type,
VALUE  v1,
VALUE  v2,
VALUE  v3,
VALUE  v0 
)

◆ rb_init_identtable()

st_table* rb_init_identtable ( void  )

Definition at line 2816 of file hash.c.

References st_init_table.

Referenced by obj_alloc_by_klass(), rb_marshal_dump_limited(), rb_marshal_load_with_proc(), and w_object().

◆ rb_init_identtable_with_size()

st_table* rb_init_identtable_with_size ( st_index_t  size)

Definition at line 2822 of file hash.c.

References st_init_table_with_size.

◆ rb_insns_name_array()

VALUE rb_insns_name_array ( void  )

Definition at line 6518 of file compile.c.

References numberof, rb_ary_new(), rb_ary_push(), rb_fstring(), rb_obj_freeze(), and rb_str_new2.

Referenced by Init_VM().

◆ rb_int2str()

VALUE rb_int2str ( VALUE  num,
int  base 
)

Definition at line 3458 of file numeric.c.

References FIXNUM_P, rb_any_to_s(), rb_big2str(), rb_fix2str(), RB_TYPE_P, and T_BIGNUM.

Referenced by int_to_s(), and rb_str_format().

◆ rb_int_abs()

VALUE rb_int_abs ( VALUE  num)

Definition at line 4644 of file numeric.c.

References fix_abs(), FIXNUM_P, Qnil, rb_big_abs(), RB_TYPE_P, and T_BIGNUM.

Referenced by f_abs(), Init_Numeric(), numeric_polar(), and rb_rational_abs().

◆ rb_int_and()

VALUE rb_int_and ( VALUE  x,
VALUE  y 
)

Definition at line 4358 of file numeric.c.

References fix_and(), FIXNUM_P, Qnil, rb_big_and(), RB_TYPE_P, and T_BIGNUM.

Referenced by Init_Numeric(), and nurat_round_half_even().

◆ rb_int_cmp()

VALUE rb_int_cmp ( VALUE  x,
VALUE  y 
)

◆ rb_int_div()

VALUE rb_int_div ( VALUE  x,
VALUE  y 
)

Definition at line 3729 of file numeric.c.

References fix_div(), FIXNUM_P, Qnil, rb_big_div(), RB_TYPE_P, and T_BIGNUM.

Referenced by f_div(), Init_Numeric(), and read_rat_nos().

◆ rb_int_divmod()

VALUE rb_int_divmod ( VALUE  x,
VALUE  y 
)

◆ rb_int_equal()

VALUE rb_int_equal ( VALUE  x,
VALUE  y 
)

Definition at line 4052 of file numeric.c.

References fix_equal(), FIXNUM_P, Qnil, rb_big_eq(), RB_TYPE_P, and T_BIGNUM.

Referenced by Init_Numeric(), and nurat_eqeq_p().

◆ rb_int_fdiv_double()

double rb_int_fdiv_double ( VALUE  x,
VALUE  y 
)

◆ rb_int_ge()

VALUE rb_int_ge ( VALUE  x,
VALUE  y 
)

Definition at line 4182 of file numeric.c.

References fix_ge(), FIXNUM_P, Qnil, rb_big_ge(), RB_TYPE_P, and T_BIGNUM.

Referenced by Init_Numeric(), and int_range_sum().

◆ rb_int_gt()

VALUE rb_int_gt ( VALUE  x,
VALUE  y 
)

Definition at line 4142 of file numeric.c.

References fix_gt(), FIXNUM_P, Qnil, rb_big_gt(), RB_TYPE_P, and T_BIGNUM.

Referenced by f_gt_p(), and Init_Numeric().

◆ rb_int_idiv()

VALUE rb_int_idiv ( VALUE  x,
VALUE  y 
)

◆ rb_int_lshift()

VALUE rb_int_lshift ( VALUE  x,
VALUE  y 
)

Definition at line 4473 of file numeric.c.

References FIXNUM_P, Qnil, rb_big_lshift(), rb_fix_lshift(), RB_TYPE_P, and T_BIGNUM.

Referenced by float_to_r(), Init_Numeric(), and rb_flt_rationalize().

◆ rb_int_minus()

VALUE rb_int_minus ( VALUE  x,
VALUE  y 
)

◆ rb_int_modulo()

VALUE rb_int_modulo ( VALUE  x,
VALUE  y 
)

◆ rb_int_mul()

VALUE rb_int_mul ( VALUE  x,
VALUE  y 
)

◆ rb_int_plus()

VALUE rb_int_plus ( VALUE  x,
VALUE  y 
)

◆ rb_int_positive_pow()

VALUE rb_int_positive_pow ( long  x,
unsigned long  y 
)

Definition at line 3949 of file numeric.c.

References int_pow().

◆ rb_int_pow()

VALUE rb_int_pow ( VALUE  x,
VALUE  y 
)

Definition at line 4011 of file numeric.c.

References fix_pow(), FIXNUM_P, Qnil, rb_big_pow(), RB_TYPE_P, and T_BIGNUM.

Referenced by float_to_r(), Init_Numeric(), nurat_expt(), and rb_flt_rationalize().

◆ rb_int_pred()

VALUE rb_int_pred ( VALUE  num)

Definition at line 3240 of file numeric.c.

References FIX2LONG, FIXNUM_P, INT2FIX, LONG2NUM, num_funcall1(), rb_big_minus(), RB_TYPE_P, and T_BIGNUM.

◆ rb_int_round()

VALUE rb_int_round ( VALUE  num,
int  ndigits,
enum ruby_num_rounding_mode  mode 
)

◆ rb_int_succ()

VALUE rb_int_succ ( VALUE  num)

Definition at line 3215 of file numeric.c.

References FIX2LONG, FIXNUM_P, INT2FIX, LONG2NUM, num_funcall1(), rb_big_plus(), RB_TYPE_P, and T_BIGNUM.

Referenced by enumerator_with_index_i().

◆ rb_int_uminus()

VALUE rb_int_uminus ( VALUE  num)

◆ rb_integer_float_cmp()

VALUE rb_integer_float_cmp ( VALUE  x,
VALUE  y 
)

◆ rb_integer_float_eq()

VALUE rb_integer_float_eq ( VALUE  x,
VALUE  y 
)

◆ rb_invcmp()

VALUE rb_invcmp ( VALUE  ,
VALUE   
)

Definition at line 46 of file compar.c.

References INT2FIX, invcmp_recursive(), NIL_P, Qnil, Qundef, rb_cmpint(), rb_exec_recursive(), and result.

Referenced by rb_str_cmp_m(), and time_cmp().

◆ rb_io_bufread()

ssize_t rb_io_bufread ( VALUE  io,
void *  buf,
size_t  size 
)

Definition at line 2176 of file io.c.

References bufread_arg::fptr, GetOpenFile, io_bufread(), and rb_io_check_readable().

◆ rb_io_flush_raw()

VALUE rb_io_flush_raw ( VALUE  ,
int   
)

◆ rb_io_memsize()

size_t rb_io_memsize ( const rb_io_t )

◆ rb_is_attrset_name()

int rb_is_attrset_name ( VALUE  name)

Definition at line 1108 of file symbol.c.

References ID_ATTRSET, IDSET_ATTRSET_FOR_INTERN, and rb_str_symname_type().

Referenced by attrsetname_to_attr().

◆ rb_is_class_name()

int rb_is_class_name ( VALUE  name)

Definition at line 1090 of file symbol.c.

References ID_CLASS, and rb_str_symname_type().

◆ rb_is_const_name()

int rb_is_const_name ( VALUE  name)

Definition at line 1084 of file symbol.c.

References ID_CONST, and rb_str_symname_type().

Referenced by new_struct(), rb_is_attr_name(), rb_mod_const_defined(), and rb_mod_const_get().

◆ rb_is_global_name()

int rb_is_global_name ( VALUE  name)

Definition at line 1096 of file symbol.c.

References ID_GLOBAL, and rb_str_symname_type().

◆ rb_is_instance_name()

int rb_is_instance_name ( VALUE  name)

Definition at line 1102 of file symbol.c.

References ID_INSTANCE, and rb_str_symname_type().

◆ rb_is_junk_name()

int rb_is_junk_name ( VALUE  name)

Definition at line 1130 of file symbol.c.

References IDSET_ATTRSET_FOR_SYNTAX, and rb_str_symname_type().

◆ rb_is_local_name()

int rb_is_local_name ( VALUE  name)

Definition at line 1114 of file symbol.c.

References ID_LOCAL, and rb_str_symname_type().

Referenced by check_local_id(), and rb_is_attr_name().

◆ rb_is_method_name()

int rb_is_method_name ( VALUE  name)

Definition at line 1120 of file symbol.c.

References FALSE, ID_ATTRSET, ID_JUNK, ID_LOCAL, rb_str_symname_type(), and TRUE.

◆ rb_ivar_lookup()

VALUE rb_ivar_lookup ( VALUE  obj,
ID  id,
VALUE  undef 
)

◆ rb_lambda_call()

VALUE rb_lambda_call ( VALUE  obj,
ID  mid,
int  argc,
const VALUE argv,
rb_block_call_func_t  bl_proc,
int  min_argc,
int  max_argc,
VALUE  data2 
)

◆ rb_last_status_clear()

void rb_last_status_clear ( void  )

Definition at line 494 of file process.c.

References GET_THREAD, and Qnil.

Referenced by fptr_waitpid(), proc_wait(), proc_waitall(), rb_f_backquote(), and rb_f_system().

◆ rb_lcm()

VALUE rb_lcm ( VALUE  x,
VALUE  y 
)

Definition at line 1868 of file rational.c.

References f_lcm(), and nurat_int_value().

Referenced by Init_Rational(), and nucomp_denominator().

◆ rb_local_defined()

int rb_local_defined ( ID  ,
const struct rb_block  
)

◆ rb_make_backtrace()

VALUE rb_make_backtrace ( void  )

Definition at line 811 of file vm_backtrace.c.

References GET_THREAD, and rb_vm_backtrace_str_ary().

◆ rb_make_internal_id()

ID rb_make_internal_id ( void  )

Definition at line 768 of file symbol.c.

References ID_INTERNAL, ID_STATIC_SYM, and next_id_base().

Referenced by Init_Exception(), and Init_pack().

◆ rb_mark_end_proc()

void rb_mark_end_proc ( void  )

◆ rb_mark_generic_ivar()

void rb_mark_generic_ivar ( VALUE  )

Definition at line 1173 of file variable.c.

References gen_ivtbl_get(), and gen_ivtbl_mark().

Referenced by gc_mark_children().

◆ rb_match_count()

int rb_match_count ( VALUE  match)

Definition at line 1266 of file re.c.

References NIL_P, re_registers::num_regs, and RMATCH_REGS.

Referenced by rb_f_global_variables().

◆ rb_match_nth_defined()

int rb_match_nth_defined ( int  nth,
VALUE  match 
)

Definition at line 1276 of file re.c.

References BEG, FALSE, NIL_P, re_registers::num_regs, and RMATCH_REGS.

Referenced by rb_f_global_variables().

◆ rb_math_atan2()

VALUE rb_math_atan2 ( VALUE  ,
VALUE   
)

Referenced by nucomp_arg().

◆ rb_math_cos()

VALUE rb_math_cos ( VALUE  )

◆ rb_math_cosh()

VALUE rb_math_cosh ( VALUE  )

◆ rb_math_exp()

VALUE rb_math_exp ( VALUE  )

◆ rb_math_hypot()

VALUE rb_math_hypot ( VALUE  ,
VALUE   
)

Referenced by nucomp_abs().

◆ rb_math_log()

VALUE rb_math_log ( int  argc,
const VALUE argv 
)

Referenced by imp1().

◆ rb_math_sin()

VALUE rb_math_sin ( VALUE  )

◆ rb_math_sinh()

VALUE rb_math_sinh ( VALUE  )

◆ rb_math_sqrt()

VALUE rb_math_sqrt ( VALUE  )

Definition at line 620 of file math.c.

References DBL2NUM, domain_error, f_signbit(), Get_Double, neg, rb_complex_abs(), rb_complex_new(), RB_TYPE_P, RCOMPLEX, and T_COMPLEX.

Referenced by math_sqrt().

◆ rb_maygvl_fd_fix_cloexec()

void rb_maygvl_fd_fix_cloexec ( int  fd)

◆ rb_method_defined_by()

int rb_method_defined_by ( VALUE  obj,
ID  mid,
VALUE(*)(ANYARGS cfunc 
)

◆ rb_mutex_allow_trap()

void rb_mutex_allow_trap ( VALUE  self,
int  val 
)

Definition at line 511 of file thread_sync.c.

References rb_mutex_struct::allow_trap, GetMutexPtr, and val.

Referenced by io_binwrite().

◆ rb_mutex_owned_p()

VALUE rb_mutex_owned_p ( VALUE  self)

Definition at line 316 of file thread_sync.c.

References GET_THREAD, GetMutexPtr, Qfalse, Qtrue, and rb_mutex_struct::th.

Referenced by finish_writeconv(), Init_thread_sync(), and io_flush_buffer().

◆ rb_name_err_new()

VALUE rb_name_err_new ( VALUE  mesg,
VALUE  recv,
VALUE  method 
)

Definition at line 1367 of file error.c.

References id_bt, id_mesg, Qnil, rb_ivar_set(), rb_name_err_mesg_new(), and rb_obj_alloc().

◆ rb_next_class_serial()

rb_serial_t rb_next_class_serial ( void  )

Definition at line 305 of file vm.c.

References NEXT_CLASS_SERIAL.

Referenced by class_alloc(), and rb_class_clear_method_cache().

◆ rb_nmin_run()

VALUE rb_nmin_run ( VALUE  obj,
VALUE  num,
int  by,
int  rev,
int  ary 
)

◆ rb_num_get_rounding_option()

enum ruby_num_rounding_mode rb_num_get_rounding_option ( VALUE  opts)

◆ rb_num_negative_p()

int rb_num_negative_p ( VALUE  )

◆ rb_num_to_dbl()

double rb_num_to_dbl ( VALUE  val)

◆ rb_num_to_uint()

int rb_num_to_uint ( VALUE  val,
unsigned int *  ret 
)

◆ rb_obj_builtin_type()

static int rb_obj_builtin_type ( VALUE  obj)
inlinestatic

Definition at line 1776 of file internal.h.

References RB_BUILTIN_TYPE, and RB_SPECIAL_CONST_P.

◆ rb_obj_copy_ivar()

void rb_obj_copy_ivar ( VALUE  dest,
VALUE  obj 
)

◆ rb_obj_dig()

VALUE rb_obj_dig ( int  argc,
VALUE argv,
VALUE  self,
VALUE  notfound 
)

◆ rb_obj_gc_flags()

size_t rb_obj_gc_flags ( VALUE  ,
ID  [],
size_t   
)

◆ rb_obj_is_fiber()

VALUE rb_obj_is_fiber ( VALUE  )

Definition at line 351 of file cont.c.

References Qfalse, Qtrue, and rb_typeddata_is_kind_of().

Referenced by rb_objspace_call_finalizer().

◆ rb_obj_is_mutex()

VALUE rb_obj_is_mutex ( VALUE  obj)

Definition at line 83 of file thread_sync.c.

References Qfalse, Qtrue, and rb_typeddata_is_kind_of().

Referenced by rb_objspace_call_finalizer().

◆ rb_obj_is_thread()

VALUE rb_obj_is_thread ( VALUE  obj)

Definition at line 2487 of file vm.c.

References Qfalse, Qtrue, rb_typeddata_is_kind_of(), and thread_data_type.

Referenced by rb_objspace_call_finalizer().

◆ rb_obj_memsize_of()

size_t rb_obj_memsize_of ( VALUE  )

Definition at line 3266 of file gc.c.

References obj_memsize_of(), and TRUE.

Referenced by cos_i(), dump_object(), iow_size(), memsize_of_m(), and total_i().

◆ rb_objid_hash()

long rb_objid_hash ( st_index_t  index)

Definition at line 251 of file hash.c.

References key64_hash(), and rb_hash_start().

Referenced by any_hash(), objid_hash(), rb_dbl_long_hash(), rb_hash(), and rb_obj_equal().

◆ rb_objspace_data_type_name()

RUBY_SYMBOL_EXPORT_BEGIN const char* rb_objspace_data_type_name ( VALUE  obj)

Definition at line 2042 of file gc.c.

References is_pointer_to_heap(), PUREFUNC(), RTYPEDDATA_P, and RTYPEDDATA_TYPE.

Referenced by cto_i(), rb_raw_obj_info(), and type_name().

◆ rb_objspace_set_event_hook()

void rb_objspace_set_event_hook ( const rb_event_flag_t  event)

◆ rb_parser_get_yydebug()

VALUE rb_parser_get_yydebug ( VALUE  )

Definition at line 17824 of file ripper.c.

◆ rb_parser_load_file()

void* rb_parser_load_file ( VALUE  parser,
VALUE  name 
)

Definition at line 2007 of file ruby.c.

References cmdline_options_init(), load_file(), and load_file_arg::opt.

Referenced by rb_load_internal0().

◆ rb_parser_set_context()

VALUE rb_parser_set_context ( VALUE  ,
const struct rb_block ,
int   
)

◆ rb_parser_set_yydebug()

VALUE rb_parser_set_yydebug ( VALUE  ,
VALUE   
)

Definition at line 17839 of file ripper.c.

◆ rb_popcount32()

static unsigned int rb_popcount32 ( uint32_t  x)
inlinestatic

Definition at line 256 of file internal.h.

Referenced by ntz_int32(), and rb_popcount_intptr().

◆ rb_popcount64()

static int rb_popcount64 ( uint64_t  x)
inlinestatic

Definition at line 270 of file internal.h.

Referenced by ntz_int64(), and rb_popcount_intptr().

◆ rb_popcount_intptr()

static int rb_popcount_intptr ( uintptr_t  x)
inlinestatic

Definition at line 285 of file internal.h.

References rb_popcount32(), and rb_popcount64().

Referenced by rb_str_init().

◆ rb_print_backtrace()

void rb_print_backtrace ( void  )

Definition at line 679 of file vm_dump.c.

References buf, cnt, ERR, free(), NULL, rb_dump_machine_register, and snprintf.

Referenced by rb_vm_bugreport(), and ruby_only_for_internal_use().

◆ rb_proc_location()

VALUE rb_proc_location ( VALUE  self)

Definition at line 1147 of file proc.c.

References iseq_location(), and rb_proc_get_iseq().

Referenced by Init_Proc(), rb_thread_inspect(), and thread_initialize().

◆ rb_rational_abs()

VALUE rb_rational_abs ( VALUE  self)

◆ rb_rational_cmp()

VALUE rb_rational_cmp ( VALUE  self,
VALUE  other 
)

◆ rb_rational_plus()

VALUE rb_rational_plus ( VALUE  self,
VALUE  other 
)

◆ rb_rational_reciprocal()

VALUE rb_rational_reciprocal ( VALUE  x)

Definition at line 1832 of file rational.c.

References CLASS_OF, f_rational_new_no_reduce2(), and get_dat1.

Referenced by fix_divide().

◆ rb_rational_uminus()

VALUE rb_rational_uminus ( VALUE  self)

◆ rb_realpath_internal()

VALUE rb_realpath_internal ( VALUE  basedir,
VALUE  path,
int  strict 
)

◆ rb_refinement_module_get_refined_class()

VALUE rb_refinement_module_get_refined_class ( VALUE  module)

Definition at line 1238 of file eval.c.

References CONST_ID, and rb_attr_get().

Referenced by ensure_includable(), include_modules_at(), rb_method_entry_make(), and rb_mod_to_s().

◆ rb_reg_check_preprocess()

VALUE rb_reg_check_preprocess ( VALUE  )

◆ rb_reg_compile()

VALUE rb_reg_compile ( VALUE  str,
int  options,
const char *  sourcefile,
int  sourceline 
)

◆ rb_reg_match_p()

VALUE rb_reg_match_p ( VALUE  re,
VALUE  str,
long  pos 
)

◆ rb_reg_search0()

long rb_reg_search0 ( VALUE  ,
VALUE  ,
long  ,
int  ,
int   
)

◆ rb_report_bug_valist()

void rb_report_bug_valist ( VALUE  file,
int  line,
const char *  fmt,
va_list  args 
)

Definition at line 558 of file error.c.

References NULL, report_bug_valist, and RSTRING_PTR.

Referenced by compile_bug().

◆ rb_require_internal()

int rb_require_internal ( VALUE  fname,
int  safe 
)

◆ rb_search_class_path()

VALUE rb_search_class_path ( VALUE  )

Definition at line 336 of file variable.c.

References never_cache(), and rb_tmp_class_path().

Referenced by ignored_block(), and rb_vm_bugreport().

◆ rb_sigaltstack_size()

int rb_sigaltstack_size ( void  )

Referenced by Init_heap(), and th_init().

◆ rb_source_loc()

const char* rb_source_loc ( int *  pline)

◆ rb_source_location()

VALUE rb_source_location ( int *  pline)

◆ rb_sourcefilename()

VALUE rb_sourcefilename ( void  )

◆ rb_st_copy()

st_table* rb_st_copy ( VALUE  obj,
struct st_table orig_tbl 
)

Definition at line 3163 of file variable.c.

References st_copy, st_data_t, st_foreach, and tbl_copy_i().

Referenced by rb_mod_init_copy(), and rb_singleton_class_clone_and_attach().

◆ rb_stdio_set_default_encoding()

void rb_stdio_set_default_encoding ( void  )

Definition at line 10957 of file io.c.

References Qnil, rb_io_set_encoding(), rb_stderr, rb_stdin, rb_stdout, and val.

Referenced by process_options().

◆ rb_str2big_karatsuba()

VALUE rb_str2big_karatsuba ( VALUE  arg,
int  base,
int  badcheck 
)

◆ rb_str2big_normal()

VALUE rb_str2big_normal ( VALUE  arg,
int  base,
int  badcheck 
)

◆ rb_str2big_poweroftwo()

VALUE rb_str2big_poweroftwo ( VALUE  arg,
int  base,
int  badcheck 
)

◆ rb_str_buf_cat_escaped_char()

int rb_str_buf_cat_escaped_char ( VALUE  result,
unsigned int  c,
int  unicode_p 
)

Definition at line 5555 of file string.c.

References buf, CHAR_ESC_LEN, ISPRINT, rb_str_buf_cat(), snprintf, and strlen().

Referenced by rb_reg_expr_str(), rb_str_escape(), and rb_str_inspect().

◆ rb_str_change_terminator_length()

void rb_str_change_terminator_length ( VALUE  str,
const int  oldtermlen,
const int  termlen 
)

◆ rb_str_chomp_string()

VALUE rb_str_chomp_string ( VALUE  str,
VALUE  chomp 
)

◆ rb_str_fill_terminator()

char* rb_str_fill_terminator ( VALUE  str,
const int  termlen 
)

Definition at line 2156 of file string.c.

References len, RSTRING_LEN, RSTRING_PTR, and str_fill_term().

Referenced by get_env_cstr().

◆ rb_str_locktmp_ensure()

VALUE rb_str_locktmp_ensure ( VALUE  str,
VALUE(*)(VALUE func,
VALUE  arg 
)

◆ rb_str_memsize()

size_t rb_str_memsize ( VALUE  )

Definition at line 1294 of file string.c.

References FL_TEST, STR_HEAP_SIZE, STR_NOEMBED, STR_NOFREE, and STR_SHARED.

Referenced by obj_memsize_of().

◆ rb_str_quote_unprintable()

VALUE rb_str_quote_unprintable ( VALUE  )

◆ rb_str_symname_p()

int rb_str_symname_p ( VALUE  )

◆ rb_str_tmp_frozen_acquire()

VALUE rb_str_tmp_frozen_acquire ( VALUE  str)

Definition at line 1135 of file string.c.

References OBJ_FROZEN_RAW, OBJ_INFECT, and str_new_frozen().

Referenced by io_fwrite(), and rb_io_syswrite().

◆ rb_str_tmp_frozen_release()

void rb_str_tmp_frozen_release ( VALUE  str,
VALUE  tmp 
)

◆ rb_struct_const_ptr()

static const VALUE* rb_struct_const_ptr ( VALUE  st)
inlinestatic

Definition at line 623 of file internal.h.

References RBignum::as, FIX_CONST_VALUE_PTR, RBASIC, RSTRUCT, and RSTRUCT_EMBED_LEN_MASK.

◆ rb_struct_init_copy()

VALUE rb_struct_init_copy ( VALUE  copy,
VALUE  s 
)

Definition at line 809 of file struct.c.

References len, OBJ_INIT_COPY, rb_eTypeError, rb_raise(), RSTRUCT_GET, RSTRUCT_LEN, and RSTRUCT_SET.

Referenced by InitVM_Struct(), and range_initialize_copy().

◆ rb_struct_len()

static long rb_struct_len ( VALUE  st)
inlinestatic

Definition at line 616 of file internal.h.

References RBASIC, RSTRUCT, RSTRUCT_EMBED_LEN, and RSTRUCT_EMBED_LEN_MASK.

◆ rb_struct_lookup()

VALUE rb_struct_lookup ( VALUE  s,
VALUE  idx 
)

Definition at line 936 of file struct.c.

References Qnil, and rb_struct_lookup_default().

Referenced by rb_obj_dig(), rb_struct_aset(), and rb_struct_dig().

◆ rb_suppress_tracing()

VALUE rb_suppress_tracing ( VALUE(*)(VALUE func,
VALUE  arg 
)

◆ rb_sym_intern_ascii()

VALUE rb_sym_intern_ascii ( const char *  ptr,
long  len 
)

Definition at line 1044 of file symbol.c.

References rb_sym_intern(), and rb_usascii_encoding().

Referenced by rb_check_symbol_cstr(), and rb_sym_intern_ascii_cstr().

◆ rb_sym_intern_ascii_cstr()

VALUE rb_sym_intern_ascii_cstr ( const char *  ptr)

◆ rb_sym_proc_call()

VALUE rb_sym_proc_call ( ID  mid,
int  argc,
const VALUE argv,
VALUE  passed_proc 
)

Definition at line 9716 of file string.c.

References rb_eArgError, rb_funcall_with_block(), rb_raise(), rb_sym_to_proc(), and sym.

Referenced by vm_yield_with_symbol(), and yield_under().

◆ rb_sym_to_proc()

VALUE rb_sym_to_proc ( VALUE  sym)

◆ rb_syntax_error_append()

VALUE rb_syntax_error_append ( VALUE  ,
VALUE  ,
int  ,
int  ,
rb_encoding ,
const char *  ,
va_list   
)

◆ rb_thread_execute_interrupts()

void rb_thread_execute_interrupts ( VALUE  th)

◆ rb_thread_io_blocking_region()

VALUE rb_thread_io_blocking_region ( rb_blocking_function_t func,
void *  data1,
int  fd 
)

◆ rb_thread_mark()

void rb_thread_mark ( void *  th)

◆ rb_thread_recycle_stack_release()

void rb_thread_recycle_stack_release ( VALUE )

Definition at line 2336 of file vm.c.

References NULL, rb_fiber_mark_self(), RECYCLE_MAX, ruby_xfree(), and VM_ASSERT.

Referenced by thread_free(), and thread_start_func_2().

◆ rb_thread_shield_destroy()

VALUE rb_thread_shield_destroy ( VALUE  self)

◆ rb_thread_shield_new()

VALUE rb_thread_shield_new ( void  )

Definition at line 4410 of file thread.c.

References DATA_PTR, rb_cThreadShield, rb_mutex_lock(), and thread_shield_alloc().

Referenced by load_lock().

◆ rb_thread_shield_release()

VALUE rb_thread_shield_release ( VALUE  self)

◆ rb_thread_shield_wait()

VALUE rb_thread_shield_wait ( VALUE  self)

◆ rb_thread_to_be_killed()

int rb_thread_to_be_killed ( VALUE  thread)

◆ rb_time_timeval()

struct timeval rb_time_timeval ( VALUE  )

◆ rb_uninterruptible()

VALUE rb_uninterruptible ( VALUE(*)(ANYARGS b_proc,
VALUE  data 
)

◆ rb_vm_add_root_module()

int rb_vm_add_root_module ( ID  id,
VALUE  module 
)

Definition at line 2153 of file vm.c.

References rb_vm_struct::defined_module_hash, GET_VM, ID2SYM, rb_hash_aset(), and TRUE.

Referenced by rb_define_class(), and rb_define_module().

◆ rb_vm_backtrace_object()

VALUE rb_vm_backtrace_object ( void  )

Definition at line 530 of file vm_backtrace.c.

References backtrace_object(), and GET_THREAD.

Referenced by raise_argument_error(), and setup_exception().

◆ rb_vm_change_state()

void rb_vm_change_state ( void  )

◆ rb_vm_check_redefinition_by_prepend()

void rb_vm_check_redefinition_by_prepend ( VALUE  klass)

◆ rb_vm_get_insns_address_table()

const void** rb_vm_get_insns_address_table ( void  )

◆ rb_vm_ifunc_new()

struct vm_ifunc* rb_vm_ifunc_new ( VALUE(*)(ANYARGS func,
const void *  data,
int  min_argc,
int  max_argc 
)

◆ rb_vm_ifunc_proc_new()

static struct vm_ifunc* rb_vm_ifunc_proc_new ( VALUE(*)(ANYARGS func,
const void *  data 
)
static

Definition at line 811 of file internal.h.

References func, rb_vm_ifunc_new(), and UNLIMITED_ARGUMENTS.

Referenced by rb_func_proc_new(), and rb_iterate().

◆ rb_vm_inc_const_missing_count()

void rb_vm_inc_const_missing_count ( void  )

Definition at line 323 of file vm.c.

Referenced by rb_const_missing().

◆ rb_vm_mark()

void rb_vm_mark ( void *  ptr)

◆ rb_vm_pop_cfunc_frame()

void rb_vm_pop_cfunc_frame ( void  )

◆ rb_vm_thread_backtrace()

VALUE rb_vm_thread_backtrace ( int  argc,
const VALUE argv,
VALUE  thval 
)

Definition at line 900 of file vm_backtrace.c.

References thread_backtrace_to_ary().

Referenced by rb_thread_backtrace_m().

◆ rb_vm_thread_backtrace_locations()

VALUE rb_vm_thread_backtrace_locations ( int  argc,
const VALUE argv,
VALUE  thval 
)

Definition at line 906 of file vm_backtrace.c.

References thread_backtrace_to_ary().

Referenced by rb_thread_backtrace_locations_m().

◆ rb_wb_protected_newobj_of()

VALUE rb_wb_protected_newobj_of ( VALUE  ,
VALUE   
)

Definition at line 1940 of file gc.c.

References assert, FL_WB_PROTECTED, newobj_of(), RGENGC_CHECK_MODE, and TRUE.

◆ rb_wb_unprotected_newobj_of()

VALUE rb_wb_unprotected_newobj_of ( VALUE  ,
VALUE   
)

Definition at line 1933 of file gc.c.

References assert, FALSE, FL_WB_PROTECTED, newobj_of(), and RGENGC_CHECK_MODE.

◆ rb_write_error_str()

void rb_write_error_str ( VALUE  mesg)

◆ rb_yield_1()

VALUE rb_yield_1 ( VALUE  val)

Definition at line 1014 of file vm_eval.c.

References rb_yield_0().

Referenced by int_dotimes(), and rb_yield().

◆ rb_yield_lambda()

VALUE rb_yield_lambda ( VALUE  values)

Definition at line 1072 of file vm_eval.c.

References GET_THREAD, and vm_yield_lambda_splattable().

Referenced by enum_yield(), and enum_yield_array().

◆ rb_yield_refine_block()

VALUE rb_yield_refine_block ( VALUE  refinement,
VALUE  refinements 
)

◆ RCLASS_SET_ORIGIN()

static void RCLASS_SET_ORIGIN ( VALUE  klass,
VALUE  origin 
)
inlinestatic

Definition at line 700 of file internal.h.

References FL_SET, RB_OBJ_WRITE, RCLASS_ORIGIN, and RICLASS_IS_ORIGIN.

Referenced by class_alloc(), and rb_prepend_module().

◆ RCLASS_SET_SUPER()

static VALUE RCLASS_SET_SUPER ( VALUE  klass,
VALUE  super 
)
inlinestatic

◆ RCLASS_SUPER()

static VALUE RCLASS_SUPER ( VALUE  klass)
inlinestatic

Definition at line 708 of file internal.h.

References RCLASS.

◆ ruby_dtoa()

char* ruby_dtoa ( double  d_,
int  mode,
int  ndigits,
int *  decpt,
int *  sign,
char **  rve 
)

◆ ruby_error_print()

void ruby_error_print ( void  )

Definition at line 185 of file eval_error.c.

References error_print(), and GET_THREAD.

Referenced by rb_f_abort().

◆ ruby_float_mod()

double ruby_float_mod ( double  x,
double  y 
)

Definition at line 1221 of file numeric.c.

References flodivmod(), and mod.

Referenced by fix_mod(), and flo_mod().

◆ ruby_float_step()

int ruby_float_step ( VALUE  from,
VALUE  to,
VALUE  step,
int  excl 
)

Definition at line 2494 of file numeric.c.

References DBL2NUM, FALSE, isinf(), NUM2DBL, RB_TYPE_P, rb_yield(), ruby_float_step_size(), T_FLOAT, TRUE, and val.

Referenced by num_step(), and range_step().

◆ ruby_gc_set_params()

void ruby_gc_set_params ( int  safe_level)

◆ ruby_get_inplace_mode()

const char* ruby_get_inplace_mode ( void  )

Definition at line 12048 of file io.c.

References ARGF.

◆ ruby_hdtoa()

char* ruby_hdtoa ( double  d,
const char *  xdigs,
int  ndigits,
int *  decpt,
int *  sign,
char **  rve 
)

◆ ruby_init_setproctitle()

void ruby_init_setproctitle ( int  argc,
char *  argv[] 
)

◆ ruby_is_fd_loadable()

int ruby_is_fd_loadable ( int  fd)

Definition at line 5697 of file file.c.

References errno, fstat, S_ISDIR, and S_ISREG.

Referenced by open_load_file(), and rb_file_load_ok().

◆ ruby_kill()

void ruby_kill ( rb_pid_t  pid,
int  sig 
)

◆ ruby_mimfree()

void ruby_mimfree ( void *  ptr)

Definition at line 8042 of file gc.c.

References free().

Referenced by ruby_vm_destruct().

◆ ruby_mimmalloc()

void* ruby_mimmalloc ( size_t  size)

Definition at line 8026 of file gc.c.

References malloc.

Referenced by Init_BareVM().

◆ ruby_num_interval_step_size()

VALUE ruby_num_interval_step_size ( VALUE  from,
VALUE  to,
VALUE  step,
int  excl 
)

◆ ruby_register_rollback_func_for_ensure()

void ruby_register_rollback_func_for_ensure ( VALUE(*)(ANYARGS ensure_func,
VALUE(*)(ANYARGS rollback_func 
)

Definition at line 977 of file cont.c.

References GET_VM, NULL, st_data_t, st_init_numtable, st_insert, and UNLIKELY.

Referenced by Init_Hash().

◆ ruby_scan_digits()

unsigned long ruby_scan_digits ( const char *  str,
ssize_t  len,
int  base,
size_t *  retlen,
int *  overflow 
)

Definition at line 84 of file util.c.

References ruby_digit36_to_number_table.

Referenced by ruby_strtoul().

◆ ruby_set_inplace_mode()

void ruby_set_inplace_mode ( const char *  )

Definition at line 12054 of file io.c.

References ARGF, free, and strdup.

Referenced by proc_options().

◆ ruby_sized_xfree()

void void ruby_sized_xfree ( void *  x,
size_t  size 
)

◆ ruby_sized_xrealloc()

void* ruby_sized_xrealloc ( void *  ptr,
size_t  new_size,
size_t  old_size 
)

Definition at line 7975 of file gc.c.

References objspace_xrealloc().

Referenced by ruby_xrealloc().

◆ ruby_sized_xrealloc2()

void* ruby_sized_xrealloc2 ( void *  ptr,
size_t  new_count,
size_t  element_size,
size_t  old_count 
)

◆ ruby_thread_has_gvl_p()

int ruby_thread_has_gvl_p ( void  )

◆ ruby_vm_special_exception_copy()

VALUE ruby_vm_special_exception_copy ( VALUE  )

Definition at line 25 of file vm_insnhelper.c.

References rb_class_real(), rb_obj_alloc(), rb_obj_copy_ivar(), and RBASIC_CLASS.

Referenced by setup_exception(), and vm_stackoverflow().

Variable Documentation

◆ OnigEncodingUS_ASCII

rb_encoding OnigEncodingUS_ASCII

◆ OnigEncodingUTF_8

rb_encoding OnigEncodingUTF_8

Definition at line 201 of file onigmo.h.

Referenced by rb_w32_sysinit().

◆ rb_cEncodingConverter

VALUE rb_cEncodingConverter

Definition at line 23 of file transcode.c.

Referenced by InitVM_transcode(), and str_cat_conv_enc_opts().

◆ rb_eEAGAIN

VALUE rb_eEAGAIN

Definition at line 46 of file error.c.

Referenced by Init_IO(), and set_syserr().

◆ rb_eEINPROGRESS

VALUE rb_eEINPROGRESS

Definition at line 48 of file error.c.

Referenced by Init_IO(), and set_syserr().

◆ rb_eEWOULDBLOCK

VALUE rb_eEWOULDBLOCK

Definition at line 47 of file error.c.

Referenced by Init_IO(), and set_syserr().

◆ ruby_digit36_to_number_table

const signed char ruby_digit36_to_number_table[]

Definition at line 6 of file escape.c.

Referenced by hex2num(), and ruby_scan_digits().

◆ ruby_digitmap

const char ruby_digitmap[]

◆ ruby_disable_gc

int ruby_disable_gc

Definition at line 814 of file gc.c.

◆ ruby_enable_coredump

int ruby_enable_coredump

Definition at line 1416 of file signal.c.

◆ ruby_engine

const char ruby_engine[]

Definition at line 35 of file version.c.

Referenced by load_file_internal(), and ruby_process_options().

◆ ruby_exec_prefix

const char ruby_exec_prefix[]

Definition at line 59 of file loadpath.c.

Referenced by ruby_init_loadpath_safe().

◆ ruby_hexdigits

const char ruby_hexdigits[]

Definition at line 5 of file escape.c.

◆ ruby_initial_gc_stress_ptr

VALUE* ruby_initial_gc_stress_ptr

Definition at line 720 of file gc.c.

Referenced by set_debug_option().

◆ ruby_initial_load_paths

const char ruby_initial_load_paths[]

Definition at line 62 of file loadpath.c.

Referenced by ruby_init_loadpath_safe().