2020-04-10 08:11:40 +03:00
|
|
|
#ifndef INTERNAL_COMPILE_H /*-*-C-*-vi:se ft=c:*/
|
|
|
|
#define INTERNAL_COMPILE_H
|
|
|
|
/**
|
2020-04-08 07:28:13 +03:00
|
|
|
* @author Ruby developers <ruby-core@ruby-lang.org>
|
2019-11-29 09:18:34 +03:00
|
|
|
* @copyright This file is a part of the programming language Ruby.
|
|
|
|
* Permission is hereby granted, to either redistribute and/or
|
|
|
|
* modify this file, provided that the conditions mentioned in the
|
|
|
|
* file COPYING are met. Consult the file for details.
|
2020-04-08 07:28:13 +03:00
|
|
|
* @brief Internal header for the compiler.
|
2019-11-29 09:18:34 +03:00
|
|
|
*/
|
2020-05-08 12:31:09 +03:00
|
|
|
#include "ruby/internal/config.h"
|
2019-12-03 10:12:39 +03:00
|
|
|
#include <stddef.h> /* for size_t */
|
|
|
|
#include "ruby/ruby.h" /* for rb_event_flag_t */
|
|
|
|
|
|
|
|
struct rb_iseq_struct; /* in vm_core.h */
|
2019-11-29 09:18:34 +03:00
|
|
|
|
|
|
|
/* compile.c */
|
|
|
|
int rb_dvar_defined(ID, const struct rb_iseq_struct *);
|
|
|
|
int rb_local_defined(ID, const struct rb_iseq_struct *);
|
2023-02-24 17:20:14 +03:00
|
|
|
int rb_insn_len(VALUE insn);
|
2019-12-03 10:12:39 +03:00
|
|
|
const char *rb_insns_name(int i);
|
2019-11-29 09:18:34 +03:00
|
|
|
VALUE rb_insns_name_array(void);
|
2021-06-03 06:32:44 +03:00
|
|
|
int rb_iseq_cdhash_cmp(VALUE val, VALUE lit);
|
|
|
|
st_index_t rb_iseq_cdhash_hash(VALUE a);
|
2019-12-03 10:12:39 +03:00
|
|
|
|
|
|
|
/* iseq.c */
|
2019-11-29 09:18:34 +03:00
|
|
|
int rb_vm_insn_addr2insn(const void *);
|
2021-06-02 11:16:49 +03:00
|
|
|
int rb_vm_insn_decode(const VALUE encoded);
|
2021-09-30 10:58:46 +03:00
|
|
|
extern bool ruby_vm_keep_script_lines;
|
2019-11-29 09:18:34 +03:00
|
|
|
|
2019-12-03 10:12:39 +03:00
|
|
|
/* iseq.c (export) */
|
|
|
|
rb_event_flag_t rb_iseq_event_flags(const struct rb_iseq_struct *iseq, size_t pos);
|
|
|
|
|
2019-11-29 09:18:34 +03:00
|
|
|
#endif /* INTERNAL_COMPILE_H */
|