6 #include "eval_intern.h"
11 rb_call_end_proc(
VALUE data)
65 if (th->top_wrapper) {
66 list = &ephemeral_end_procs;
78 rb_mark_end_proc(
void)
87 link = ephemeral_end_procs;
99 VALUE errinfo = *errp;
101 while ((link = *procs) != 0) {
105 (*endproc.func) (endproc.data);
113 enum ruby_tag_type state;
114 volatile VALUE errinfo = ec->errinfo;
117 if ((state = EC_EXEC_TAG()) == TAG_NONE) {
119 exec_end_procs_chain(&ephemeral_end_procs, &ec->errinfo);
120 exec_end_procs_chain(&end_procs, &ec->errinfo);
124 error_handle(ec, state);
125 if (!
NIL_P(ec->errinfo)) errinfo = ec->errinfo;
131 ec->errinfo = errinfo;
int rb_block_given_p(void)
Determines if the current method is given a block.
void rb_define_global_function(const char *name, VALUE(*func)(ANYARGS), int argc)
Defines a global function.
#define ALLOC
Old name of RB_ALLOC.
#define xfree
Old name of ruby_xfree.
#define NIL_P
Old name of RB_NIL_P.
void rb_raise(VALUE exc, const char *fmt,...)
Exception entry point.
VALUE rb_eArgError
ArgumentError exception.
VALUE rb_ary_new(void)
Allocates a new, empty array.
void rb_set_end_proc(void(*func)(VALUE arg), VALUE arg)
Registers a function that shall run on process exit.
void rb_gc_mark(VALUE obj)
Marks an object.
VALUE rb_proc_call(VALUE recv, VALUE args)
Evaluates the passed proc with the passed arguments.
VALUE rb_block_proc(void)
Constructs a Proc object from implicitly passed components.
#define _(args)
This was a transition path from K&R to ANSI.
uintptr_t VALUE
Type that represents a Ruby object.