did_you_mean 0.9.2 → 0.9.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (112) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +24 -0
  3. data/ext/did_you_mean/extconf.rb +0 -23
  4. data/ext/did_you_mean/method_missing.c +8 -97
  5. data/ext/did_you_mean/org/yukinishijima/ReceiverCapturer.java +1 -2
  6. data/lib/did_you_mean/finders/similar_method_finder.rb +2 -1
  7. data/lib/did_you_mean/version.rb +1 -1
  8. data/test/no_method_error_extension_test.rb +1 -1
  9. metadata +2 -105
  10. data/ext/did_you_mean/ruby_headers/193/debug.h +0 -41
  11. data/ext/did_you_mean/ruby_headers/193/id.h +0 -171
  12. data/ext/did_you_mean/ruby_headers/193/internal.h +0 -242
  13. data/ext/did_you_mean/ruby_headers/193/method.h +0 -105
  14. data/ext/did_you_mean/ruby_headers/193/node.h +0 -504
  15. data/ext/did_you_mean/ruby_headers/193/ruby_atomic.h +0 -122
  16. data/ext/did_you_mean/ruby_headers/193/thread_pthread.h +0 -51
  17. data/ext/did_you_mean/ruby_headers/193/thread_win32.h +0 -40
  18. data/ext/did_you_mean/ruby_headers/193/vm_core.h +0 -763
  19. data/ext/did_you_mean/ruby_headers/193/vm_opts.h +0 -51
  20. data/ext/did_you_mean/ruby_headers/200/id.h +0 -171
  21. data/ext/did_you_mean/ruby_headers/200/internal.h +0 -392
  22. data/ext/did_you_mean/ruby_headers/200/method.h +0 -138
  23. data/ext/did_you_mean/ruby_headers/200/node.h +0 -539
  24. data/ext/did_you_mean/ruby_headers/200/ruby_atomic.h +0 -165
  25. data/ext/did_you_mean/ruby_headers/200/thread_pthread.h +0 -56
  26. data/ext/did_you_mean/ruby_headers/200/thread_win32.h +0 -45
  27. data/ext/did_you_mean/ruby_headers/200/vm_core.h +0 -1013
  28. data/ext/did_you_mean/ruby_headers/200/vm_debug.h +0 -41
  29. data/ext/did_you_mean/ruby_headers/200/vm_opts.h +0 -56
  30. data/ext/did_you_mean/ruby_headers/210/id.h +0 -173
  31. data/ext/did_you_mean/ruby_headers/210/internal.h +0 -889
  32. data/ext/did_you_mean/ruby_headers/210/method.h +0 -142
  33. data/ext/did_you_mean/ruby_headers/210/node.h +0 -543
  34. data/ext/did_you_mean/ruby_headers/210/ruby_atomic.h +0 -165
  35. data/ext/did_you_mean/ruby_headers/210/thread_native.h +0 -23
  36. data/ext/did_you_mean/ruby_headers/210/thread_pthread.h +0 -56
  37. data/ext/did_you_mean/ruby_headers/210/thread_win32.h +0 -45
  38. data/ext/did_you_mean/ruby_headers/210/vm_core.h +0 -1043
  39. data/ext/did_you_mean/ruby_headers/210/vm_debug.h +0 -37
  40. data/ext/did_you_mean/ruby_headers/210/vm_opts.h +0 -56
  41. data/ext/did_you_mean/ruby_headers/211/id.h +0 -173
  42. data/ext/did_you_mean/ruby_headers/211/internal.h +0 -889
  43. data/ext/did_you_mean/ruby_headers/211/method.h +0 -142
  44. data/ext/did_you_mean/ruby_headers/211/node.h +0 -543
  45. data/ext/did_you_mean/ruby_headers/211/ruby_atomic.h +0 -170
  46. data/ext/did_you_mean/ruby_headers/211/thread_native.h +0 -23
  47. data/ext/did_you_mean/ruby_headers/211/thread_pthread.h +0 -56
  48. data/ext/did_you_mean/ruby_headers/211/thread_win32.h +0 -45
  49. data/ext/did_you_mean/ruby_headers/211/vm_core.h +0 -1043
  50. data/ext/did_you_mean/ruby_headers/211/vm_debug.h +0 -37
  51. data/ext/did_you_mean/ruby_headers/211/vm_opts.h +0 -56
  52. data/ext/did_you_mean/ruby_headers/212/id.h +0 -173
  53. data/ext/did_you_mean/ruby_headers/212/internal.h +0 -889
  54. data/ext/did_you_mean/ruby_headers/212/method.h +0 -142
  55. data/ext/did_you_mean/ruby_headers/212/node.h +0 -543
  56. data/ext/did_you_mean/ruby_headers/212/ruby_atomic.h +0 -170
  57. data/ext/did_you_mean/ruby_headers/212/thread_native.h +0 -23
  58. data/ext/did_you_mean/ruby_headers/212/thread_pthread.h +0 -56
  59. data/ext/did_you_mean/ruby_headers/212/thread_win32.h +0 -45
  60. data/ext/did_you_mean/ruby_headers/212/vm_core.h +0 -1043
  61. data/ext/did_you_mean/ruby_headers/212/vm_debug.h +0 -37
  62. data/ext/did_you_mean/ruby_headers/212/vm_opts.h +0 -56
  63. data/ext/did_you_mean/ruby_headers/213/id.h +0 -173
  64. data/ext/did_you_mean/ruby_headers/213/internal.h +0 -892
  65. data/ext/did_you_mean/ruby_headers/213/method.h +0 -142
  66. data/ext/did_you_mean/ruby_headers/213/node.h +0 -543
  67. data/ext/did_you_mean/ruby_headers/213/ruby_atomic.h +0 -170
  68. data/ext/did_you_mean/ruby_headers/213/thread_native.h +0 -23
  69. data/ext/did_you_mean/ruby_headers/213/thread_pthread.h +0 -56
  70. data/ext/did_you_mean/ruby_headers/213/thread_win32.h +0 -45
  71. data/ext/did_you_mean/ruby_headers/213/vm_core.h +0 -1052
  72. data/ext/did_you_mean/ruby_headers/213/vm_debug.h +0 -37
  73. data/ext/did_you_mean/ruby_headers/213/vm_opts.h +0 -56
  74. data/ext/did_you_mean/ruby_headers/214/id.h +0 -173
  75. data/ext/did_you_mean/ruby_headers/214/internal.h +0 -892
  76. data/ext/did_you_mean/ruby_headers/214/method.h +0 -142
  77. data/ext/did_you_mean/ruby_headers/214/node.h +0 -543
  78. data/ext/did_you_mean/ruby_headers/214/ruby_atomic.h +0 -170
  79. data/ext/did_you_mean/ruby_headers/214/thread_native.h +0 -23
  80. data/ext/did_you_mean/ruby_headers/214/thread_pthread.h +0 -56
  81. data/ext/did_you_mean/ruby_headers/214/thread_win32.h +0 -45
  82. data/ext/did_you_mean/ruby_headers/214/vm_core.h +0 -1055
  83. data/ext/did_you_mean/ruby_headers/214/vm_debug.h +0 -37
  84. data/ext/did_you_mean/ruby_headers/214/vm_opts.h +0 -56
  85. data/ext/did_you_mean/ruby_headers/215/id.h +0 -173
  86. data/ext/did_you_mean/ruby_headers/215/internal.h +0 -892
  87. data/ext/did_you_mean/ruby_headers/215/method.h +0 -142
  88. data/ext/did_you_mean/ruby_headers/215/node.h +0 -543
  89. data/ext/did_you_mean/ruby_headers/215/ruby_atomic.h +0 -170
  90. data/ext/did_you_mean/ruby_headers/215/thread_native.h +0 -23
  91. data/ext/did_you_mean/ruby_headers/215/thread_pthread.h +0 -56
  92. data/ext/did_you_mean/ruby_headers/215/thread_win32.h +0 -45
  93. data/ext/did_you_mean/ruby_headers/215/vm_core.h +0 -1055
  94. data/ext/did_you_mean/ruby_headers/215/vm_debug.h +0 -37
  95. data/ext/did_you_mean/ruby_headers/215/vm_opts.h +0 -56
  96. data/ext/did_you_mean/ruby_headers/220/ccan/check_type/check_type.h +0 -63
  97. data/ext/did_you_mean/ruby_headers/220/ccan/container_of/container_of.h +0 -106
  98. data/ext/did_you_mean/ruby_headers/220/ccan/list/list.h +0 -602
  99. data/ext/did_you_mean/ruby_headers/220/ccan/str/str.h +0 -16
  100. data/ext/did_you_mean/ruby_headers/220/id.h +0 -173
  101. data/ext/did_you_mean/ruby_headers/220/internal.h +0 -1106
  102. data/ext/did_you_mean/ruby_headers/220/method.h +0 -141
  103. data/ext/did_you_mean/ruby_headers/220/node.h +0 -544
  104. data/ext/did_you_mean/ruby_headers/220/ruby_atomic.h +0 -170
  105. data/ext/did_you_mean/ruby_headers/220/symbol.h +0 -87
  106. data/ext/did_you_mean/ruby_headers/220/thread_native.h +0 -23
  107. data/ext/did_you_mean/ruby_headers/220/thread_pthread.h +0 -54
  108. data/ext/did_you_mean/ruby_headers/220/thread_win32.h +0 -36
  109. data/ext/did_you_mean/ruby_headers/220/vm_core.h +0 -1160
  110. data/ext/did_you_mean/ruby_headers/220/vm_debug.h +0 -37
  111. data/ext/did_you_mean/ruby_headers/220/vm_opts.h +0 -56
  112. data/ext/did_you_mean/vm_method.c +0 -28
@@ -1,51 +0,0 @@
1
- /*-*-c-*-*/
2
- /**********************************************************************
3
-
4
- vm_opts.h - VM optimize option
5
-
6
- $Author$
7
-
8
- Copyright (C) 2004-2007 Koichi Sasada
9
-
10
- **********************************************************************/
11
-
12
-
13
- #ifndef RUBY_VM_OPTS_H
14
- #define RUBY_VM_OPTS_H
15
-
16
- /* Compile options.
17
- * You can change these options at runtime by VM::CompileOption.
18
- * Following definitions are default values.
19
- */
20
-
21
- #define OPT_TRACE_INSTRUCTION 1
22
- #define OPT_TAILCALL_OPTIMIZATION 0
23
- #define OPT_PEEPHOLE_OPTIMIZATION 1
24
- #define OPT_SPECIALISED_INSTRUCTION 1
25
- #define OPT_INLINE_CONST_CACHE 1
26
-
27
-
28
- /* Build Options.
29
- * You can't change these options at runtime.
30
- */
31
-
32
- /* C compiler depend */
33
- #define OPT_DIRECT_THREADED_CODE 1
34
- #define OPT_TOKEN_THREADED_CODE 0
35
- #define OPT_CALL_THREADED_CODE 0
36
-
37
- /* VM running option */
38
- #define OPT_CHECKED_RUN 1
39
- #define OPT_INLINE_METHOD_CACHE 1
40
- #define OPT_BLOCKINLINING 0
41
-
42
- /* architecture independent, affects generated code */
43
- #define OPT_OPERANDS_UNIFICATION 0
44
- #define OPT_INSTRUCTIONS_UNIFICATION 0
45
- #define OPT_UNIFY_ALL_COMBINATION 0
46
- #define OPT_STACK_CACHING 0
47
-
48
- /* misc */
49
- #define SUPPORT_JOKE 0
50
-
51
- #endif /* RUBY_VM_OPTS_H */
@@ -1,171 +0,0 @@
1
- /* DO NOT EDIT THIS FILE DIRECTLY */
2
- /**********************************************************************
3
-
4
- id.h -
5
-
6
- $Author$
7
- created at: Sun Oct 19 21:12:51 2008
8
-
9
- Copyright (C) 2007 Koichi Sasada
10
-
11
- **********************************************************************/
12
-
13
- #ifndef RUBY_ID_H
14
- #define RUBY_ID_H
15
-
16
- enum ruby_id_types {
17
- RUBY_ID_LOCAL = 0x00,
18
- RUBY_ID_INSTANCE = 0x01,
19
- RUBY_ID_GLOBAL = 0x03,
20
- RUBY_ID_ATTRSET = 0x04,
21
- RUBY_ID_CONST = 0x05,
22
- RUBY_ID_CLASS = 0x06,
23
- RUBY_ID_JUNK = 0x07,
24
- RUBY_ID_INTERNAL = RUBY_ID_JUNK,
25
- RUBY_ID_SCOPE_SHIFT = 3,
26
- RUBY_ID_SCOPE_MASK = ~(~0U<<RUBY_ID_SCOPE_SHIFT)
27
- };
28
-
29
- #define ID_SCOPE_SHIFT RUBY_ID_SCOPE_SHIFT
30
- #define ID_SCOPE_MASK RUBY_ID_SCOPE_MASK
31
- #define ID_LOCAL RUBY_ID_LOCAL
32
- #define ID_INSTANCE RUBY_ID_INSTANCE
33
- #define ID_GLOBAL RUBY_ID_GLOBAL
34
- #define ID_ATTRSET RUBY_ID_ATTRSET
35
- #define ID_CONST RUBY_ID_CONST
36
- #define ID_CLASS RUBY_ID_CLASS
37
- #define ID_JUNK RUBY_ID_JUNK
38
- #define ID_INTERNAL RUBY_ID_INTERNAL
39
-
40
- #define ID2ATTRSET(id) (((id)&~ID_SCOPE_MASK)|ID_ATTRSET)
41
-
42
- #define symIFUNC ID2SYM(idIFUNC)
43
- #define symCFUNC ID2SYM(idCFUNC)
44
-
45
- #define RUBY_TOKEN_DOT2 128
46
- #define RUBY_TOKEN_DOT3 129
47
- #define RUBY_TOKEN_UPLUS 130
48
- #define RUBY_TOKEN_UMINUS 131
49
- #define RUBY_TOKEN_POW 132
50
- #define RUBY_TOKEN_DSTAR 133
51
- #define RUBY_TOKEN_CMP 134
52
- #define RUBY_TOKEN_LSHFT 135
53
- #define RUBY_TOKEN_RSHFT 136
54
- #define RUBY_TOKEN_LEQ 137
55
- #define RUBY_TOKEN_GEQ 138
56
- #define RUBY_TOKEN_EQ 139
57
- #define RUBY_TOKEN_EQQ 140
58
- #define RUBY_TOKEN_NEQ 141
59
- #define RUBY_TOKEN_MATCH 142
60
- #define RUBY_TOKEN_NMATCH 143
61
- #define RUBY_TOKEN_AREF 144
62
- #define RUBY_TOKEN_ASET 145
63
- #define RUBY_TOKEN_COLON2 146
64
- #define RUBY_TOKEN_COLON3 147
65
- #define RUBY_TOKEN(t) RUBY_TOKEN_##t
66
-
67
- enum ruby_method_ids {
68
- idDot2 = RUBY_TOKEN(DOT2),
69
- idDot3 = RUBY_TOKEN(DOT3),
70
- idUPlus = RUBY_TOKEN(UPLUS),
71
- idUMinus = RUBY_TOKEN(UMINUS),
72
- idPow = RUBY_TOKEN(POW),
73
- idCmp = RUBY_TOKEN(CMP),
74
- idPLUS = '+',
75
- idMINUS = '-',
76
- idMULT = '*',
77
- idDIV = '/',
78
- idMOD = '%',
79
- idLT = '<',
80
- idLTLT = RUBY_TOKEN(LSHFT),
81
- idLE = RUBY_TOKEN(LEQ),
82
- idGT = '>',
83
- idGE = RUBY_TOKEN(GEQ),
84
- idEq = RUBY_TOKEN(EQ),
85
- idEqq = RUBY_TOKEN(EQQ),
86
- idNeq = RUBY_TOKEN(NEQ),
87
- idNot = '!',
88
- idBackquote = '`',
89
- idEqTilde = RUBY_TOKEN(MATCH),
90
- idNeqTilde = RUBY_TOKEN(NMATCH),
91
- idAREF = RUBY_TOKEN(AREF),
92
- idASET = RUBY_TOKEN(ASET),
93
- tPRESERVED_ID_BEGIN = 147,
94
- idNULL,
95
- idEmptyP,
96
- idEqlP,
97
- idRespond_to,
98
- idRespond_to_missing,
99
- idIFUNC,
100
- idCFUNC,
101
- id_core_set_method_alias,
102
- id_core_set_variable_alias,
103
- id_core_undef_method,
104
- id_core_define_method,
105
- id_core_define_singleton_method,
106
- id_core_set_postexe,
107
- id_core_hash_from_ary,
108
- id_core_hash_merge_ary,
109
- id_core_hash_merge_ptr,
110
- id_core_hash_merge_kwd,
111
- tPRESERVED_ID_END,
112
- tFreeze,
113
- tInspect,
114
- tIntern,
115
- tObject_id,
116
- tConst_missing,
117
- tMethodMissing,
118
- tMethod_added,
119
- tSingleton_method_added,
120
- tMethod_removed,
121
- tSingleton_method_removed,
122
- tMethod_undefined,
123
- tSingleton_method_undefined,
124
- tLength,
125
- tSize,
126
- tGets,
127
- tSucc,
128
- tEach,
129
- tProc,
130
- tLambda,
131
- tSend,
132
- t__send__,
133
- t__attached__,
134
- tInitialize,
135
- tInitialize_copy,
136
- tInitialize_clone,
137
- tInitialize_dup,
138
- tUScore,
139
- #define TOKEN2LOCALID(n) id##n = ((t##n<<ID_SCOPE_SHIFT)|ID_LOCAL)
140
- TOKEN2LOCALID(Freeze),
141
- TOKEN2LOCALID(Inspect),
142
- TOKEN2LOCALID(Intern),
143
- TOKEN2LOCALID(Object_id),
144
- TOKEN2LOCALID(Const_missing),
145
- TOKEN2LOCALID(MethodMissing),
146
- TOKEN2LOCALID(Method_added),
147
- TOKEN2LOCALID(Singleton_method_added),
148
- TOKEN2LOCALID(Method_removed),
149
- TOKEN2LOCALID(Singleton_method_removed),
150
- TOKEN2LOCALID(Method_undefined),
151
- TOKEN2LOCALID(Singleton_method_undefined),
152
- TOKEN2LOCALID(Length),
153
- TOKEN2LOCALID(Size),
154
- TOKEN2LOCALID(Gets),
155
- TOKEN2LOCALID(Succ),
156
- TOKEN2LOCALID(Each),
157
- TOKEN2LOCALID(Proc),
158
- TOKEN2LOCALID(Lambda),
159
- TOKEN2LOCALID(Send),
160
- TOKEN2LOCALID(__send__),
161
- TOKEN2LOCALID(__attached__),
162
- TOKEN2LOCALID(Initialize),
163
- TOKEN2LOCALID(Initialize_copy),
164
- TOKEN2LOCALID(Initialize_clone),
165
- TOKEN2LOCALID(Initialize_dup),
166
- TOKEN2LOCALID(UScore),
167
- tLAST_OP_ID = tPRESERVED_ID_END-1,
168
- idLAST_OP_ID = tLAST_OP_ID >> ID_SCOPE_SHIFT
169
- };
170
-
171
- #endif /* RUBY_ID_H */
@@ -1,392 +0,0 @@
1
- /**********************************************************************
2
-
3
- internal.h -
4
-
5
- $Author$
6
- created at: Tue May 17 11:42:20 JST 2011
7
-
8
- Copyright (C) 2011 Yukihiro Matsumoto
9
-
10
- **********************************************************************/
11
-
12
- #ifndef RUBY_INTERNAL_H
13
- #define RUBY_INTERNAL_H 1
14
-
15
- #if defined(__cplusplus)
16
- extern "C" {
17
- #if 0
18
- } /* satisfy cc-mode */
19
- #endif
20
- #endif
21
-
22
- #define MUL_OVERFLOW_SIGNED_INTEGER_P(a, b, min, max) ( \
23
- (a) == 0 ? 0 : \
24
- (a) == -1 ? (b) < -(max) : \
25
- (a) > 0 ? \
26
- ((b) > 0 ? (max) / (a) < (b) : (min) / (a) > (b)) : \
27
- ((b) > 0 ? (min) / (a) < (b) : (max) / (a) > (b)))
28
- #define MUL_OVERFLOW_FIXNUM_P(a, b) MUL_OVERFLOW_SIGNED_INTEGER_P(a, b, FIXNUM_MIN, FIXNUM_MAX)
29
- #define MUL_OVERFLOW_LONG_P(a, b) MUL_OVERFLOW_SIGNED_INTEGER_P(a, b, LONG_MIN, LONG_MAX)
30
-
31
- struct rb_deprecated_classext_struct {
32
- char conflict[sizeof(VALUE) * 3];
33
- };
34
-
35
- struct rb_classext_struct {
36
- VALUE super;
37
- struct st_table *iv_tbl;
38
- struct st_table *const_tbl;
39
- VALUE origin;
40
- VALUE refined_class;
41
- rb_alloc_func_t allocator;
42
- };
43
-
44
- #undef RCLASS_SUPER
45
- #define RCLASS_EXT(c) (RCLASS(c)->ptr)
46
- #define RCLASS_SUPER(c) (RCLASS_EXT(c)->super)
47
- #define RCLASS_IV_TBL(c) (RCLASS_EXT(c)->iv_tbl)
48
- #define RCLASS_CONST_TBL(c) (RCLASS_EXT(c)->const_tbl)
49
- #define RCLASS_M_TBL(c) (RCLASS(c)->m_tbl)
50
- #define RCLASS_IV_INDEX_TBL(c) (RCLASS(c)->iv_index_tbl)
51
- #define RCLASS_ORIGIN(c) (RCLASS_EXT(c)->origin)
52
- #define RCLASS_REFINED_CLASS(c) (RCLASS_EXT(c)->refined_class)
53
-
54
- struct vtm; /* defined by timev.h */
55
-
56
- /* array.c */
57
- VALUE rb_ary_last(int, VALUE *, VALUE);
58
- void rb_ary_set_len(VALUE, long);
59
- VALUE rb_ary_cat(VALUE, const VALUE *, long);
60
- void rb_ary_delete_same(VALUE, VALUE);
61
-
62
- /* bignum.c */
63
- VALUE rb_big_fdiv(VALUE x, VALUE y);
64
- VALUE rb_big_uminus(VALUE x);
65
- VALUE rb_integer_float_cmp(VALUE x, VALUE y);
66
- VALUE rb_integer_float_eq(VALUE x, VALUE y);
67
-
68
- /* class.c */
69
- VALUE rb_obj_methods(int argc, VALUE *argv, VALUE obj);
70
- VALUE rb_obj_protected_methods(int argc, VALUE *argv, VALUE obj);
71
- VALUE rb_obj_private_methods(int argc, VALUE *argv, VALUE obj);
72
- VALUE rb_obj_public_methods(int argc, VALUE *argv, VALUE obj);
73
- int rb_obj_basic_to_s_p(VALUE);
74
- VALUE rb_special_singleton_class(VALUE);
75
- VALUE rb_singleton_class_clone_and_attach(VALUE obj, VALUE attach);
76
- void Init_class_hierarchy(void);
77
-
78
- /* compar.c */
79
- VALUE rb_invcmp(VALUE, VALUE);
80
-
81
- /* compile.c */
82
- int rb_dvar_defined(ID);
83
- int rb_local_defined(ID);
84
- int rb_parse_in_eval(void);
85
- int rb_parse_in_main(void);
86
- const char * rb_insns_name(int i);
87
- VALUE rb_insns_name_array(void);
88
-
89
- /* cont.c */
90
- VALUE rb_obj_is_fiber(VALUE);
91
- void rb_fiber_reset_root_local_storage(VALUE);
92
-
93
- /* debug.c */
94
- PRINTF_ARGS(void ruby_debug_printf(const char*, ...), 1, 2);
95
-
96
- /* dmyext.c */
97
- void Init_ext(void);
98
-
99
- /* encoding.c */
100
- ID rb_id_encoding(void);
101
-
102
- /* encoding.c */
103
- void rb_gc_mark_encodings(void);
104
-
105
- /* error.c */
106
- NORETURN(PRINTF_ARGS(void rb_compile_bug(const char*, int, const char*, ...), 3, 4));
107
- VALUE rb_check_backtrace(VALUE);
108
- NORETURN(void rb_async_bug_errno(const char *,int));
109
- const char *rb_builtin_type_name(int t);
110
- const char *rb_builtin_class_name(VALUE x);
111
-
112
- /* eval.c */
113
- VALUE rb_refinement_module_get_refined_class(VALUE module);
114
-
115
- /* eval_error.c */
116
- void ruby_error_print(void);
117
- VALUE rb_get_backtrace(VALUE info);
118
-
119
- /* eval_jump.c */
120
- void rb_call_end_proc(VALUE data);
121
- void rb_mark_end_proc(void);
122
-
123
- /* file.c */
124
- VALUE rb_home_dir(const char *user, VALUE result);
125
- VALUE rb_realpath_internal(VALUE basedir, VALUE path, int strict);
126
- void rb_file_const(const char*, VALUE);
127
- int rb_file_load_ok(const char *);
128
- VALUE rb_file_expand_path_fast(VALUE, VALUE);
129
- VALUE rb_file_expand_path_internal(VALUE, VALUE, int, int, VALUE);
130
- VALUE rb_get_path_check_to_string(VALUE, int);
131
- VALUE rb_get_path_check_convert(VALUE, VALUE, int);
132
- void Init_File(void);
133
-
134
- #ifdef _WIN32
135
- /* file.c, win32/file.c */
136
- void rb_w32_init_file(void);
137
- #endif
138
-
139
- /* gc.c */
140
- void Init_heap(void);
141
- void *ruby_mimmalloc(size_t size);
142
-
143
- /* inits.c */
144
- void rb_call_inits(void);
145
-
146
- /* io.c */
147
- const char *ruby_get_inplace_mode(void);
148
- void ruby_set_inplace_mode(const char *);
149
- ssize_t rb_io_bufread(VALUE io, void *buf, size_t size);
150
- void rb_stdio_set_default_encoding(void);
151
- void rb_write_error_str(VALUE mesg);
152
-
153
- /* iseq.c */
154
- VALUE rb_iseq_clone(VALUE iseqval, VALUE newcbase);
155
-
156
- /* load.c */
157
- VALUE rb_get_load_path(void);
158
- VALUE rb_get_expanded_load_path(void);
159
- NORETURN(void rb_load_fail(VALUE, const char*));
160
-
161
- /* math.c */
162
- VALUE rb_math_atan2(VALUE, VALUE);
163
- VALUE rb_math_cos(VALUE);
164
- VALUE rb_math_cosh(VALUE);
165
- VALUE rb_math_exp(VALUE);
166
- VALUE rb_math_hypot(VALUE, VALUE);
167
- VALUE rb_math_log(int argc, VALUE *argv);
168
- VALUE rb_math_sin(VALUE);
169
- VALUE rb_math_sinh(VALUE);
170
- VALUE rb_math_sqrt(VALUE);
171
-
172
- /* newline.c */
173
- void Init_newline(void);
174
-
175
- /* numeric.c */
176
- int rb_num_to_uint(VALUE val, unsigned int *ret);
177
- VALUE num_interval_step_size(VALUE from, VALUE to, VALUE step, int excl);
178
- int ruby_float_step(VALUE from, VALUE to, VALUE step, int excl);
179
- double ruby_float_mod(double x, double y);
180
- int rb_num_negative_p(VALUE);
181
- VALUE rb_int_succ(VALUE num);
182
- VALUE rb_int_pred(VALUE num);
183
-
184
- /* object.c */
185
- VALUE rb_obj_equal(VALUE obj1, VALUE obj2);
186
-
187
- /* parse.y */
188
- VALUE rb_parser_get_yydebug(VALUE);
189
- VALUE rb_parser_set_yydebug(VALUE, VALUE);
190
- int rb_is_const_name(VALUE name);
191
- int rb_is_class_name(VALUE name);
192
- int rb_is_global_name(VALUE name);
193
- int rb_is_instance_name(VALUE name);
194
- int rb_is_attrset_name(VALUE name);
195
- int rb_is_local_name(VALUE name);
196
- int rb_is_method_name(VALUE name);
197
- int rb_is_junk_name(VALUE name);
198
- void rb_gc_mark_parser(void);
199
- void rb_gc_mark_symbols(void);
200
-
201
- /* proc.c */
202
- VALUE rb_proc_location(VALUE self);
203
- st_index_t rb_hash_proc(st_index_t hash, VALUE proc);
204
-
205
- /* process.c */
206
- #define RB_MAX_GROUPS (65536)
207
-
208
- struct rb_execarg {
209
- int use_shell;
210
- union {
211
- struct {
212
- VALUE shell_script;
213
- } sh;
214
- struct {
215
- VALUE command_name;
216
- VALUE command_abspath; /* full path string or nil */
217
- VALUE argv_str;
218
- VALUE argv_buf;
219
- } cmd;
220
- } invoke;
221
- VALUE redirect_fds;
222
- VALUE envp_str;
223
- VALUE envp_buf;
224
- VALUE dup2_tmpbuf;
225
- unsigned pgroup_given : 1;
226
- unsigned umask_given : 1;
227
- unsigned unsetenv_others_given : 1;
228
- unsigned unsetenv_others_do : 1;
229
- unsigned close_others_given : 1;
230
- unsigned close_others_do : 1;
231
- unsigned chdir_given : 1;
232
- unsigned new_pgroup_given : 1;
233
- unsigned new_pgroup_flag : 1;
234
- unsigned uid_given : 1;
235
- unsigned gid_given : 1;
236
- rb_pid_t pgroup_pgid; /* asis(-1), new pgroup(0), specified pgroup (0<V). */
237
- VALUE rlimit_limits; /* Qfalse or [[rtype, softlim, hardlim], ...] */
238
- mode_t umask_mask;
239
- rb_uid_t uid;
240
- rb_gid_t gid;
241
- VALUE fd_dup2;
242
- VALUE fd_close;
243
- VALUE fd_open;
244
- VALUE fd_dup2_child;
245
- int close_others_maxhint;
246
- VALUE env_modification; /* Qfalse or [[k1,v1], ...] */
247
- VALUE chdir_dir;
248
- };
249
-
250
- /* argv_str contains extra two elements.
251
- * The beginning one is for /bin/sh used by exec_with_sh.
252
- * The last one for terminating NULL used by execve.
253
- * See rb_exec_fillarg() in process.c. */
254
- #define ARGVSTR2ARGC(argv_str) (RSTRING_LEN(argv_str) / sizeof(char *) - 2)
255
- #define ARGVSTR2ARGV(argv_str) ((char **)RSTRING_PTR(argv_str) + 1)
256
-
257
- rb_pid_t rb_fork_ruby(int *status);
258
- void rb_last_status_clear(void);
259
-
260
- /* rational.c */
261
- VALUE rb_lcm(VALUE x, VALUE y);
262
- VALUE rb_rational_reciprocal(VALUE x);
263
-
264
- /* re.c */
265
- VALUE rb_reg_compile(VALUE str, int options, const char *sourcefile, int sourceline);
266
- VALUE rb_reg_check_preprocess(VALUE);
267
-
268
- /* signal.c */
269
- int rb_get_next_signal(void);
270
- int rb_sigaltstack_size(void);
271
-
272
- /* strftime.c */
273
- #ifdef RUBY_ENCODING_H
274
- size_t rb_strftime_timespec(char *s, size_t maxsize, const char *format, rb_encoding *enc,
275
- const struct vtm *vtm, struct timespec *ts, int gmt);
276
- size_t rb_strftime(char *s, size_t maxsize, const char *format, rb_encoding *enc,
277
- const struct vtm *vtm, VALUE timev, int gmt);
278
- #endif
279
-
280
- /* string.c */
281
- int rb_str_buf_cat_escaped_char(VALUE result, unsigned int c, int unicode_p);
282
- int rb_str_symname_p(VALUE);
283
- VALUE rb_str_quote_unprintable(VALUE);
284
- VALUE rb_id_quote_unprintable(ID);
285
- #define QUOTE(str) rb_str_quote_unprintable(str)
286
- #define QUOTE_ID(id) rb_id_quote_unprintable(id)
287
- VALUE rb_str_locktmp_ensure(VALUE str, VALUE (*func)(VALUE), VALUE arg);
288
-
289
- /* struct.c */
290
- VALUE rb_struct_init_copy(VALUE copy, VALUE s);
291
-
292
- /* time.c */
293
- struct timeval rb_time_timeval(VALUE);
294
-
295
- /* thread.c */
296
- VALUE rb_obj_is_mutex(VALUE obj);
297
- VALUE rb_suppress_tracing(VALUE (*func)(VALUE), VALUE arg);
298
- void rb_thread_execute_interrupts(VALUE th);
299
- void rb_clear_trace_func(void);
300
- VALUE rb_get_coverages(void);
301
- VALUE rb_thread_shield_new(void);
302
- VALUE rb_thread_shield_wait(VALUE self);
303
- VALUE rb_thread_shield_release(VALUE self);
304
- VALUE rb_thread_shield_destroy(VALUE self);
305
- void rb_mutex_allow_trap(VALUE self, int val);
306
- VALUE rb_uninterruptible(VALUE (*b_proc)(ANYARGS), VALUE data);
307
- VALUE rb_mutex_owned_p(VALUE self);
308
-
309
- /* thread_pthread.c, thread_win32.c */
310
- void Init_native_thread(void);
311
-
312
- /* vm.c */
313
- VALUE rb_obj_is_thread(VALUE obj);
314
- void rb_vm_mark(void *ptr);
315
- void Init_BareVM(void);
316
- VALUE rb_vm_top_self(void);
317
- void rb_thread_recycle_stack_release(VALUE *);
318
- void rb_vm_change_state(void);
319
- void rb_vm_inc_const_missing_count(void);
320
- void rb_thread_mark(void *th);
321
- const void **rb_vm_get_insns_address_table(void);
322
- VALUE rb_sourcefilename(void);
323
-
324
- /* vm_dump.c */
325
- void rb_vm_bugreport(void);
326
-
327
- /* vm_eval.c */
328
- void Init_vm_eval(void);
329
- VALUE rb_current_realfilepath(void);
330
- VALUE rb_check_block_call(VALUE, ID, int, VALUE *, VALUE (*)(ANYARGS), VALUE);
331
- typedef void rb_check_funcall_hook(int, VALUE, ID, int, VALUE *, VALUE);
332
- VALUE rb_check_funcall_with_hook(VALUE recv, ID mid, int argc, VALUE *argv,
333
- rb_check_funcall_hook *hook, VALUE arg);
334
-
335
- /* vm_method.c */
336
- void Init_eval_method(void);
337
- int rb_method_defined_by(VALUE obj, ID mid, VALUE (*cfunc)(ANYARGS));
338
-
339
- /* miniprelude.c, prelude.c */
340
- void Init_prelude(void);
341
-
342
- /* vm_backtrace.c */
343
- void Init_vm_backtrace(void);
344
- VALUE vm_thread_backtrace(int argc, VALUE *argv, VALUE thval);
345
- VALUE vm_thread_backtrace_locations(int argc, VALUE *argv, VALUE thval);
346
-
347
- VALUE rb_make_backtrace(void);
348
- void rb_backtrace_print_as_bugreport(void);
349
- int rb_backtrace_p(VALUE obj);
350
- VALUE rb_backtrace_to_str_ary(VALUE obj);
351
- VALUE rb_vm_backtrace_object();
352
-
353
- #if defined __GNUC__ && __GNUC__ >= 4
354
- #pragma GCC visibility push(default)
355
- #endif
356
- const char *rb_objspace_data_type_name(VALUE obj);
357
-
358
- /* Temporary. This API will be removed (renamed). */
359
- VALUE rb_thread_io_blocking_region(rb_blocking_function_t *func, void *data1, int fd);
360
-
361
- /* io.c */
362
- void rb_maygvl_fd_fix_cloexec(int fd);
363
-
364
- /* process.c */
365
- int rb_exec_async_signal_safe(const struct rb_execarg *e, char *errmsg, size_t errmsg_buflen);
366
- rb_pid_t rb_fork_async_signal_safe(int *status, int (*chfunc)(void*, char *, size_t), void *charg, VALUE fds, char *errmsg, size_t errmsg_buflen);
367
- VALUE rb_execarg_new(int argc, VALUE *argv, int accept_shell);
368
- struct rb_execarg *rb_execarg_get(VALUE execarg_obj); /* dangerous. needs GC guard. */
369
- VALUE rb_execarg_init(int argc, VALUE *argv, int accept_shell, VALUE execarg_obj);
370
- int rb_execarg_addopt(VALUE execarg_obj, VALUE key, VALUE val);
371
- void rb_execarg_fixup(VALUE execarg_obj);
372
- int rb_execarg_run_options(const struct rb_execarg *e, struct rb_execarg *s, char* errmsg, size_t errmsg_buflen);
373
- VALUE rb_execarg_extract_options(VALUE execarg_obj, VALUE opthash);
374
- void rb_execarg_setenv(VALUE execarg_obj, VALUE env);
375
-
376
- /* variable.c */
377
- void rb_gc_mark_global_tbl(void);
378
- void rb_mark_generic_ivar(VALUE);
379
- void rb_mark_generic_ivar_tbl(void);
380
-
381
- #if defined __GNUC__ && __GNUC__ >= 4
382
- #pragma GCC visibility pop
383
- #endif
384
-
385
- #if defined(__cplusplus)
386
- #if 0
387
- { /* satisfy cc-mode */
388
- #endif
389
- } /* extern "C" { */
390
- #endif
391
-
392
- #endif /* RUBY_INTERNAL_H */