Ruby  2.0.0p353(2013-11-22revision43784)
iseq.h
Go to the documentation of this file.
1 /**********************************************************************
2 
3  iseq.h -
4 
5  $Author: nagachika $
6  created at: 04/01/01 23:36:57 JST
7 
8  Copyright (C) 2004-2008 Koichi Sasada
9 
10 **********************************************************************/
11 
12 #ifndef RUBY_COMPILE_H
13 #define RUBY_COMPILE_H
14 
15 #if defined __GNUC__ && __GNUC__ >= 4
16 #pragma GCC visibility push(default)
17 #endif
18 
19 /* compile.c */
23  VALUE exception, VALUE body);
24 
25 /* iseq.c */
26 void rb_iseq_add_mark_object(rb_iseq_t *iseq, VALUE obj);
27 VALUE rb_iseq_load(VALUE data, VALUE parent, VALUE opt);
28 VALUE rb_iseq_parameters(const rb_iseq_t *iseq, int is_proc);
30 unsigned int rb_iseq_line_no(const rb_iseq_t *iseq, size_t pos);
31 
32 int rb_iseq_line_trace_each(VALUE iseqval, int (*func)(int line, rb_event_flag_t *events_ptr, void *d), void *data);
35 
36 /* proc.c */
38 rb_iseq_t *rb_proc_get_iseq(VALUE proc, int *is_proc);
39 
50 };
51 
53  unsigned int position;
54  unsigned int line_no;
55 };
56 
58  enum catch_type {
65  } type;
67  unsigned long start;
68  unsigned long end;
69  unsigned long cont;
70  unsigned long sp;
71 };
72 
73 #define INITIAL_ISEQ_COMPILE_DATA_STORAGE_BUFF_SIZE (512)
74 
77  unsigned long pos;
78  unsigned long size;
79  char *buff;
80 };
81 
83  /* GC is needed */
86  VALUE catch_table_ary; /* Array */
87 
88  /* GC is not needed */
96  int loopval_popped; /* used by NODE_BREAK */
102  int label_no;
105 #if SUPPORT_JOKE
106  st_table *labels_table;
107 #endif
108 };
109 
110 /* defined? */
111 
130 };
131 
133 
134 #define DEFAULT_SPECIAL_VAR_COUNT 2
135 
136 #if defined __GNUC__ && __GNUC__ >= 4
137 #pragma GCC visibility pop
138 #endif
139 
140 #endif /* RUBY_COMPILE_H */
catch_type
Definition: iseq.h:58
unsigned long size
Definition: iseq.h:78
Definition: st.h:77
unsigned long end
Definition: iseq.h:68
unsigned int rb_iseq_line_no(const rb_iseq_t *iseq, size_t pos)
Definition: iseq.c:1110
Definition: iseq.h:61
struct iseq_compile_data_storage * storage_head
Definition: iseq.h:98
VALUE catch_table_ary
Definition: iseq.h:86
struct st_table * ruby_insn_make_insn_table(void)
SSL_METHOD *(* func)(void)
Definition: ossl_ssl.c:108
struct iseq_label_data * start_label
Definition: iseq.h:89
struct iseq_compile_data_storage * next
Definition: iseq.h:76
struct iseq_compile_data_ensure_node_stack * ensure_node_stack
Definition: iseq.h:95
VALUE current_block
Definition: iseq.h:92
const rb_compile_option_t * option
Definition: iseq.h:104
Definition: node.h:239
enum iseq_catch_table_entry::catch_type type
unsigned long pos
Definition: iseq.h:77
int args
Definition: win32ole.c:785
VALUE rb_iseq_parameters(const rb_iseq_t *iseq, int is_proc)
Definition: iseq.c:1926
int specialized_instruction
Definition: iseq.h:44
Definition: iseq.h:59
VALUE mark_ary
Definition: iseq.h:85
int instructions_unification
Definition: iseq.h:46
VALUE rb_iseq_defined_string(enum defined_type type)
Definition: iseq.c:2000
VALUE rb_iseq_compile_node(VALUE self, NODE *node)
Definition: compile.c:461
VALUE rb_iseq_load(VALUE data, VALUE parent, VALUE opt)
Definition: iseq.c:571
unsigned long start
Definition: iseq.h:67
Definition: iseq.h:60
Definition: iseq.h:64
defined_type
Definition: iseq.h:112
struct iseq_label_data * redo_label
Definition: iseq.h:91
rb_iseq_t * rb_proc_get_iseq(VALUE proc, int *is_proc)
Definition: proc.c:713
int type
Definition: tcltklib.c:111
unsigned long VALUE
Definition: ruby.h:104
Definition: iseq.h:57
Definition: iseq.h:62
VALUE err_info
Definition: iseq.h:84
Definition: iseq.h:63
unsigned long sp
Definition: iseq.h:70
#define INT2FIX(i)
Definition: ruby.h:241
unsigned int position
Definition: iseq.h:53
VALUE ensure_node
Definition: iseq.h:93
void rb_iseq_add_mark_object(rb_iseq_t *iseq, VALUE obj)
Definition: iseq.c:244
VALUE rb_iseq_line_trace_specify(VALUE iseqval, VALUE pos, VALUE set)
Definition: iseq.c:2194
unsigned long rb_event_flag_t
Definition: ruby.h:1603
VALUE rb_iseq_build_from_ary(rb_iseq_t *iseq, VALUE locals, VALUE args, VALUE exception, VALUE body)
Definition: compile.c:5758
int cached_const
Definition: iseq.h:97
VALUE for_iseq
Definition: iseq.h:94
struct iseq_compile_data_storage * storage_current
Definition: iseq.h:99
int last_coverable_line
Definition: iseq.h:101
rb_iseq_t * rb_method_get_iseq(VALUE body)
Definition: proc.c:1859
int rb_iseq_translate_threaded_code(rb_iseq_t *iseq)
Definition: compile.c:559
VALUE rb_iseq_line_trace_all(VALUE iseqval)
Definition: iseq.c:2147
unsigned long cont
Definition: iseq.h:69
struct iseq_label_data * end_label
Definition: iseq.h:90
int loopval_popped
Definition: iseq.h:96
VALUE iseq
Definition: iseq.h:66
int rb_iseq_line_trace_each(VALUE iseqval, int(*func)(int line, rb_event_flag_t *events_ptr, void *d), void *data)
Definition: iseq.c:2100
Definition: iseq.h:52
int node_level
Definition: iseq.h:103
unsigned int line_no
Definition: iseq.h:54