Ruby 4.0.5p0 (2026-05-20 revision 64336ffd0ee9e1f4c05891695a3d7b49cb709721)
RObject Struct Reference

Ruby's ordinal objects. More...

#include <robject.h>

Data Fields

struct RBasic basic
 Basic part, including flags and class.
union { 
   struct { 
      VALUE *   fields 
 Pointer to a C array that holds instance variables. More...
   }   heap
 Object that use separated memory region for instance variables use this pattern. More...
   VALUE   ary [1] 
as
 Object's specific fields.

Detailed Description

Ruby's ordinal objects.

Unless otherwise special cased, all predefined and user-defined classes share this struct to hold their instances.

Definition at line 85 of file robject.h.

Field Documentation

◆ ary

VALUE RObject::ary[1]

Definition at line 110 of file robject.h.

◆ [union]

union { ... } RObject::as

Object's specific fields.

◆ basic

struct RBasic RObject::basic

Basic part, including flags and class.

Definition at line 88 of file robject.h.

◆ fields

VALUE* RObject::fields

Pointer to a C array that holds instance variables.

Definition at line 99 of file robject.h.

◆ [struct]

struct { ... } RObject::heap

Object that use separated memory region for instance variables use this pattern.


The documentation for this struct was generated from the following file: