Ruby: rb_classext_struct Struct Reference

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

Data Fields
rb_classext_struct Struct Reference

## Data Fields
const rb_box_t * | box
VALUE | super
VALUE | fields_obj
struct rb_id_table * | m_tbl
struct rb_id_table * | const_tbl
struct rb_id_table * | callable_m_tbl
VALUE | cc_tbl
VALUE | cvc_tbl
VALUE * | superclasses
struct rb_subclass_entry * | subclasses
| The head of the subclasses linked list.
struct rb_subclass_entry * | subclass_entry
| Back-pointer to this class's entry in its superclass's subclasses list.
struct rb_subclass_entry * | module_subclass_entry
| In the case that this is an ICLASS, module_subclass_entry points to the entry in the module's subclasses list that indicates that the klass has been included.
const VALUE | origin_
const VALUE | refined_class
union { |
struct { |
rb_alloc_func_t allocator |
} class
struct { |
VALUE attached_object |
} singleton_class
struct { |
const VALUE includer |
} iclass
} | as
attr_index_t | max_iv_count
uint16_t | superclass_depth
unsigned char | variation_count
bool | permanent_classpath: 1
bool | cloned: 1
bool | shared_const_tbl: 1
bool | iclass_is_origin: 1
bool | iclass_origin_shared_mtbl: 1
bool | superclasses_with_self: 1
VALUE | classpath

## Detailed Description

Definition at line 45 of file class.h.

## Field Documentation

## ◆ allocator

rb_alloc_func_t rb_classext_struct::allocator

Definition at line 76 of file class.h.

## ◆ attached_object

VALUE rb_classext_struct::attached_object

Definition at line 79 of file class.h.

## ◆ box

const rb_box_t* rb_classext_struct::box

Definition at line 46 of file class.h.

## ◆ callable_m_tbl

struct rb_id_table* rb_classext_struct::callable_m_tbl

Definition at line 51 of file class.h.

## ◆ cc_tbl

VALUE rb_classext_struct::cc_tbl

Definition at line 52 of file class.h.

## ◆ classpath

VALUE rb_classext_struct::classpath

Definition at line 94 of file class.h.

## ◆ cloned

bool rb_classext_struct::cloned

Definition at line 89 of file class.h.

## ◆ const_tbl

struct rb_id_table* rb_classext_struct::const_tbl

Definition at line 50 of file class.h.

## ◆ cvc_tbl

VALUE rb_classext_struct::cvc_tbl

Definition at line 53 of file class.h.

## ◆ fields_obj

VALUE rb_classext_struct::fields_obj

Definition at line 48 of file class.h.

## ◆ iclass_is_origin

bool rb_classext_struct::iclass_is_origin

Definition at line 91 of file class.h.

## ◆ iclass_origin_shared_mtbl

bool rb_classext_struct::iclass_origin_shared_mtbl

Definition at line 92 of file class.h.

## ◆ includer

const VALUE rb_classext_struct::includer

Definition at line 82 of file class.h.

## ◆ m_tbl

struct rb_id_table* rb_classext_struct::m_tbl

Definition at line 49 of file class.h.

## ◆ max_iv_count

attr_index_t rb_classext_struct::max_iv_count

Definition at line 85 of file class.h.

## ◆ module_subclass_entry

struct rb_subclass_entry* rb_classext_struct::module_subclass_entry

In the case that this is an ICLASS, module_subclass_entry points to the entry in the module's subclasses list that indicates that the klass has been included.

Used for O(1) removal.

Definition at line 70 of file class.h.

## ◆ origin_

const VALUE rb_classext_struct::origin_

Definition at line 72 of file class.h.

## ◆ permanent_classpath

bool rb_classext_struct::permanent_classpath

Definition at line 88 of file class.h.

## ◆ refined_class

const VALUE rb_classext_struct::refined_class

Definition at line 73 of file class.h.

## ◆ shared_const_tbl

bool rb_classext_struct::shared_const_tbl

Definition at line 90 of file class.h.

## ◆ subclass_entry

struct rb_subclass_entry* rb_classext_struct::subclass_entry

Back-pointer to this class's entry in its superclass's subclasses list.

Used for O(1) removal when the class is freed.

Definition at line 64 of file class.h.

## ◆ subclasses

struct rb_subclass_entry* rb_classext_struct::subclasses

The head of the subclasses linked list.

This is a dummy entry (klass == 0) whose next points to the first real entry. Only used in prime classext.

Definition at line 59 of file class.h.

## ◆ super

VALUE rb_classext_struct::super

Definition at line 47 of file class.h.

## ◆ superclass_depth

uint16_t rb_classext_struct::superclass_depth

Definition at line 86 of file class.h.

## ◆ superclasses

VALUE* rb_classext_struct::superclasses

Definition at line 54 of file class.h.

## ◆ superclasses_with_self

bool rb_classext_struct::superclasses_with_self

Definition at line 93 of file class.h.

## ◆ variation_count

unsigned char rb_classext_struct::variation_count

Definition at line 87 of file class.h.

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

- internal/class.h