Ruby: internal/proc.h Source File

Ruby 3.2.5p208 (2024-07-26 revision 31d0f1a2e7dbfb60731d1f05b868e1d578cda493)

proc.h
1#ifndef INTERNAL_PROC_H /*-*-C-*-vi:se ft=c:*/
2#define INTERNAL_PROC_H
11#include "ruby/ruby.h" /* for rb_block_call_func_t */
12#include "ruby/st.h" /* for st_index_t */
13struct rb_block; /* in vm_core.h */
14struct rb_iseq_struct; /* in vm_core.h */
15
16/* proc.c */
17 VALUE rb_proc_location(VALUE self);
18st_index_t rb_hash_proc(st_index_t hash, VALUE proc);
19int rb_block_pair_yield_optimizable(void);
20int rb_block_arity(void);
21int rb_block_min_max_arity(int *max);
22 VALUE rb_block_to_s(VALUE self, const struct rb_block *block, const char *additional_info);
23 VALUE rb_callable_receiver(VALUE);
24
25MJIT_SYMBOL_EXPORT_BEGIN
26 VALUE rb_func_proc_new(rb_block_call_func_t func, VALUE val);
27 VALUE rb_func_lambda_new(rb_block_call_func_t func, VALUE val, int min_argc, int max_argc);
28 VALUE rb_iseq_location(const struct rb_iseq_struct *iseq);
29 VALUE rb_sym_to_proc(VALUE sym);
30MJIT_SYMBOL_EXPORT_END
31
32#endif /* INTERNAL_PROC_H */
rb_block_call_func_t
rb_block_call_func * rb_block_call_func_t
Shorthand type that represents an iterator-written-in-C function pointer.
Definition iterator.h:88
ruby.h
rb_block
Definition vm_core.h:809
rb_iseq_struct
Definition vm_core.h:526
VALUE
uintptr_t VALUE
Type that represents a Ruby object.
Definition value.h:40