Ruby: include/ruby/internal/intern/variable.h Source File

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

variable.h
Go to the documentation of this file.
1#ifndef RBIMPL_INTERN_VARIABLE_H /*-*-C++-*-vi:se ft=cpp:*/
2#define RBIMPL_INTERN_VARIABLE_H
23#include "ruby/internal/attr/noreturn.h"
24#include "ruby/internal/dllexport.h"
25#include "ruby/internal/value.h"
26#include "ruby/st.h"
27
28 RBIMPL_SYMBOL_EXPORT_BEGIN()
29
30/* variable.c */
31 VALUE rb_mod_name(VALUE);
32 VALUE rb_class_path(VALUE);
33 VALUE rb_class_path_cached(VALUE);
34void rb_set_class_path(VALUE, VALUE, const char*);
35void rb_set_class_path_string(VALUE, VALUE, VALUE);
36 VALUE rb_path_to_class(VALUE);
37 VALUE rb_path2class(const char*);
38 VALUE rb_class_name(VALUE);
39 VALUE rb_autoload_load(VALUE, ID);
40 VALUE rb_autoload_p(VALUE, ID);
41 VALUE rb_f_trace_var(int, const VALUE*);
42 VALUE rb_f_untrace_var(int, const VALUE*);
43 VALUE rb_f_global_variables(void);
44void rb_alias_variable(ID, ID);
45void rb_copy_generic_ivar(VALUE,VALUE);
46void rb_free_generic_ivar(VALUE);
47 VALUE rb_ivar_get(VALUE, ID);
48 VALUE rb_ivar_set(VALUE, ID, VALUE);
49 VALUE rb_ivar_defined(VALUE, ID);
50 void rb_ivar_foreach(VALUE, int (*)(ID, VALUE, st_data_t), st_data_t);
51 st_index_t rb_ivar_count(VALUE);
52 VALUE rb_attr_get(VALUE, ID);
53 VALUE rb_obj_instance_variables(VALUE);
54 VALUE rb_obj_remove_instance_variable(VALUE, VALUE);
55void *rb_mod_const_at(VALUE, void*);
56void *rb_mod_const_of(VALUE, void*);
57 VALUE rb_const_list(void*);
58 VALUE rb_mod_constants(int, const VALUE *, VALUE);
59 VALUE rb_mod_remove_const(VALUE, VALUE);
60int rb_const_defined(VALUE, ID);
61int rb_const_defined_at(VALUE, ID);
62int rb_const_defined_from(VALUE, ID);
63 VALUE rb_const_get(VALUE, ID);
64 VALUE rb_const_get_at(VALUE, ID);
65 VALUE rb_const_get_from(VALUE, ID);
66void rb_const_set(VALUE, ID, VALUE);
67 VALUE rb_const_remove(VALUE, ID);
68#if 0 /* EXPERIMENTAL: remove if no problem */
69 RBIMPL_ATTR_NORETURN()
70 VALUE rb_mod_const_missing(VALUE,VALUE);
71#endif
72 VALUE rb_cvar_defined(VALUE, ID);
73void rb_cvar_set(VALUE, ID, VALUE);
74 VALUE rb_cvar_get(VALUE, ID);
75void rb_cv_set(VALUE, const char*, VALUE);
76 VALUE rb_cv_get(VALUE, const char*);
77void rb_define_class_variable(VALUE, const char*, VALUE);
78 VALUE rb_mod_class_variables(int, const VALUE*, VALUE);
79 VALUE rb_mod_remove_cvar(VALUE, VALUE);
80
81 RBIMPL_SYMBOL_EXPORT_END()
82
83#endif /* RBIMPL_INTERN_VARIABLE_H */
rb_mod_const_missing
VALUE rb_mod_const_missing(VALUE, VALUE)
Definition: variable.c:1960
dllexport.h
Tewaking visibility of C variables/functions.
RBIMPL_SYMBOL_EXPORT_END
#define RBIMPL_SYMBOL_EXPORT_END()
Counterpart of RBIMPL_SYMBOL_EXPORT_BEGIN.
Definition: dllexport.h:86
RBIMPL_SYMBOL_EXPORT_BEGIN
#define RBIMPL_SYMBOL_EXPORT_BEGIN()
Shortcut macro equivalent to RUBY_SYMBOL_EXPORT_BEGIN extern "C" {.
Definition: dllexport.h:77
rb_obj_instance_variables
#define rb_obj_instance_variables(object)
Definition: generator.h:20
rb_class_name
VALUE rb_class_name(VALUE)
Definition: variable.c:293
rb_f_trace_var
VALUE rb_f_trace_var(int, const VALUE *)
Definition: variable.c:610
rb_class_path_cached
VALUE rb_class_path_cached(VALUE)
Definition: variable.c:178
rb_set_class_path_string
void rb_set_class_path_string(VALUE, VALUE, VALUE)
Definition: variable.c:214
rb_const_get
VALUE rb_const_get(VALUE, ID)
Definition: variable.c:2624
rb_set_class_path
void rb_set_class_path(VALUE, VALUE, const char *)
Definition: variable.c:234
rb_mod_class_variables
VALUE rb_mod_class_variables(int, const VALUE *, VALUE)
Definition: variable.c:3512
rb_copy_generic_ivar
void rb_copy_generic_ivar(VALUE, VALUE)
Definition: variable.c:1638
rb_path2class
VALUE rb_path2class(const char *)
Definition: variable.c:287
rb_cvar_defined
VALUE rb_cvar_defined(VALUE, ID)
Definition: variable.c:3387
rb_const_list
VALUE rb_const_list(void *)
Definition: variable.c:2840
rb_ivar_get
VALUE rb_ivar_get(VALUE, ID)
Definition: variable.c:1234
rb_ivar_count
st_index_t rb_ivar_count(VALUE)
Definition: variable.c:1733
rb_free_generic_ivar
void rb_free_generic_ivar(VALUE)
Definition: variable.c:1157
rb_f_untrace_var
VALUE rb_f_untrace_var(int, const VALUE *)
Definition: variable.c:656
rb_cv_get
VALUE rb_cv_get(VALUE, const char *)
Definition: variable.c:3413
rb_const_defined_at
int rb_const_defined_at(VALUE, ID)
Definition: variable.c:2934
rb_cvar_set
void rb_cvar_set(VALUE, ID, VALUE)
Definition: variable.c:3346
rb_class_path
VALUE rb_class_path(VALUE)
Definition: variable.c:169
rb_path_to_class
VALUE rb_path_to_class(VALUE)
Definition: variable.c:242
rb_const_get_at
VALUE rb_const_get_at(VALUE, ID)
Definition: variable.c:2630
rb_ivar_foreach
void rb_ivar_foreach(VALUE, int(*)(ID, VALUE, st_data_t), st_data_t)
rb_const_get_from
VALUE rb_const_get_from(VALUE, ID)
Definition: variable.c:2618
rb_ivar_defined
VALUE rb_ivar_defined(VALUE, ID)
Definition: variable.c:1510
rb_obj_remove_instance_variable
VALUE rb_obj_remove_instance_variable(VALUE, VALUE)
Definition: variable.c:1856
rb_cvar_get
VALUE rb_cvar_get(VALUE, ID)
Definition: variable.c:3371
rb_define_class_variable
void rb_define_class_variable(VALUE, const char *, VALUE)
Definition: variable.c:3420
rb_const_set
void rb_const_set(VALUE, ID, VALUE)
Definition: variable.c:3003
rb_mod_remove_const
VALUE rb_mod_remove_const(VALUE, VALUE)
Definition: variable.c:2716
rb_mod_constants
VALUE rb_mod_constants(int, const VALUE *, VALUE)
Definition: variable.c:2872
rb_attr_get
VALUE rb_attr_get(VALUE, ID)
Definition: variable.c:1242
rb_alias_variable
void rb_alias_variable(ID, ID)
Definition: variable.c:843
rb_mod_const_of
void * rb_mod_const_of(VALUE, void *)
Definition: variable.c:2818
rb_mod_const_at
void * rb_mod_const_at(VALUE, void *)
Definition: variable.c:2801
rb_const_defined_from
int rb_const_defined_from(VALUE, ID)
Definition: variable.c:2922
rb_ivar_set
VALUE rb_ivar_set(VALUE, ID, VALUE)
Definition: variable.c:1493
rb_const_remove
VALUE rb_const_remove(VALUE, ID)
Definition: variable.c:2727
rb_autoload_load
VALUE rb_autoload_load(VALUE, ID)
Definition: variable.c:2452
rb_f_global_variables
VALUE rb_f_global_variables(void)
Definition: variable.c:811
rb_mod_remove_cvar
VALUE rb_mod_remove_cvar(VALUE, VALUE)
Definition: variable.c:3547
rb_autoload_p
VALUE rb_autoload_p(VALUE, ID)
Definition: variable.c:2511
rb_cv_set
void rb_cv_set(VALUE, const char *, VALUE)
Definition: variable.c:3406
rb_mod_name
VALUE rb_mod_name(VALUE)
Definition: variable.c:118
rb_const_defined
int rb_const_defined(VALUE, ID)
Definition: variable.c:2928
noreturn.h
Defines RBIMPL_ATTR_NORETURN.
RBIMPL_ATTR_NORETURN
#define RBIMPL_ATTR_NORETURN()
Wraps (or simulates) [[noreturn]]
Definition: noreturn.h:38
st.h
st_data_t
unsigned long st_data_t
Definition: st.h:22
st_index_t
st_data_t st_index_t
Definition: st.h:50
const
#define const
Definition: strftime.c:108
value.h
Defines VALUE and ID.
VALUE
unsigned long VALUE
Definition: value.h:38
ID
unsigned long ID
Definition: value.h:39