debase-ruby_core_source 3.3.0 → 3.3.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/Rakefile +2 -1
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/ast.h +4612 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/defines.h +94 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/diagnostic.h +297 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/encoding.h +248 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/extension.h +18 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/node.h +57 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/options.h +204 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/pack.h +152 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/parser.h +716 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/prettyprint.h +26 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/prism.h +272 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/regexp.h +33 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/util/pm_buffer.h +146 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/util/pm_char.h +205 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/util/pm_constant_pool.h +191 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/util/pm_list.h +97 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/util/pm_memchr.h +29 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/util/pm_newline_list.h +104 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/util/pm_state_stack.h +42 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/util/pm_string.h +150 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/util/pm_string_list.h +44 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/util/pm_strncasecmp.h +32 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/util/pm_strpbrk.h +43 -0
- data/lib/debase/ruby_core_source/ruby-3.3.0-p0/prism/version.h +29 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/addr2line.h +22 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/builtin.h +117 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/ccan/build_assert/build_assert.h +40 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/ccan/check_type/check_type.h +63 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/ccan/container_of/container_of.h +142 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/ccan/list/list.h +791 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/ccan/str/str.h +17 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/constant.h +53 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/darray.h +246 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/debug_counter.h +423 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/dln.h +32 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/encindex.h +70 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/eval_intern.h +343 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/hrtime.h +227 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/id.h +343 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/id_table.h +39 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/insns.inc +251 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/insns_info.inc +9215 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/array.h +151 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/basic_operators.h +63 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/bignum.h +244 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/bits.h +568 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/class.h +277 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/cmdlineopt.h +65 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/compar.h +29 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/compile.h +34 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/compilers.h +107 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/complex.h +29 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/cont.h +35 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/dir.h +16 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/enc.h +19 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/encoding.h +35 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/enum.h +18 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/enumerator.h +21 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/error.h +216 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/eval.h +33 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/file.h +38 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/fixnum.h +184 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/gc.h +364 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/hash.h +191 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/imemo.h +240 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/inits.h +50 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/io.h +137 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/load.h +18 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/loadpath.h +16 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/math.h +23 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/missing.h +18 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/numeric.h +273 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/object.h +62 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/parse.h +108 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/proc.h +30 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/process.h +124 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/ractor.h +6 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/random.h +17 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/range.h +40 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/rational.h +71 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/re.h +28 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/ruby_parser.h +69 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/sanitizers.h +186 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/serial.h +23 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/signal.h +25 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/static_assert.h +16 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/string.h +160 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/struct.h +127 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/symbol.h +45 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/thread.h +78 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/time.h +34 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/transcode.h +23 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/util.h +27 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/variable.h +72 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/vm.h +136 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal/warnings.h +16 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/internal.h +112 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/iseq.h +338 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/known_errors.inc +791 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/method.h +254 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/node.h +128 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/node_name.inc +212 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/optinsn.inc +128 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/optunifs.inc +43 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/parse.h +243 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/parser_bits.h +564 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/parser_node.h +32 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/parser_st.h +162 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/parser_value.h +106 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/ast.h +4612 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/defines.h +94 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/diagnostic.h +297 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/encoding.h +248 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/extension.h +18 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/node.h +57 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/options.h +204 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/pack.h +152 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/parser.h +716 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/prettyprint.h +26 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/prism.h +272 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/regexp.h +33 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/util/pm_buffer.h +146 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/util/pm_char.h +205 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/util/pm_constant_pool.h +191 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/util/pm_list.h +97 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/util/pm_memchr.h +29 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/util/pm_newline_list.h +104 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/util/pm_state_stack.h +42 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/util/pm_string.h +150 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/util/pm_string_list.h +44 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/util/pm_strncasecmp.h +32 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/util/pm_strpbrk.h +43 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism/version.h +29 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/prism_compile.h +29 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/probes_helper.h +42 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/ractor_core.h +393 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/regenc.h +254 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/regint.h +1006 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/regparse.h +371 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/revision.h +5 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/rjit.h +101 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/rjit_c.h +164 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/ruby_assert.h +14 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/ruby_atomic.h +23 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/rubyparser.h +1405 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/shape.h +233 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/siphash.h +48 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/symbol.h +118 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/thread_none.h +21 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/thread_pthread.h +166 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/thread_win32.h +58 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/timev.h +58 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/transcode_data.h +138 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/variable.h +39 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/version.h +69 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/vm.inc +5436 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/vm_call_iseq_optimized.inc +244 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/vm_callinfo.h +614 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/vm_core.h +2202 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/vm_debug.h +122 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/vm_exec.h +199 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/vm_insnhelper.h +261 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/vm_opts.h +67 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/vm_sync.h +137 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/vmtc.inc +245 -0
- data/lib/debase/ruby_core_source/ruby-3.3.5-p100/yjit.h +72 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/addr2line.h +22 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/builtin.h +119 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/ccan/build_assert/build_assert.h +40 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/ccan/check_type/check_type.h +63 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/ccan/container_of/container_of.h +142 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/ccan/list/list.h +791 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/ccan/str/str.h +17 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/constant.h +53 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/darray.h +191 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/debug_counter.h +423 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/dln.h +34 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/encindex.h +70 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/eval_intern.h +324 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/hrtime.h +237 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/id.h +343 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/id_table.h +39 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/insns.inc +259 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/insns_info.inc +9530 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/array.h +151 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/basic_operators.h +63 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/bignum.h +244 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/bits.h +568 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/class.h +283 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/cmdlineopt.h +65 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/compar.h +29 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/compile.h +34 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/compilers.h +107 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/complex.h +29 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/cont.h +35 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/dir.h +16 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/enc.h +19 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/encoding.h +36 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/enum.h +18 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/enumerator.h +21 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/error.h +216 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/eval.h +33 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/file.h +38 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/fixnum.h +184 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/gc.h +334 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/hash.h +191 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/imemo.h +260 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/inits.h +47 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/io.h +140 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/load.h +18 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/loadpath.h +16 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/math.h +23 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/missing.h +19 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/numeric.h +274 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/object.h +63 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/parse.h +117 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/proc.h +30 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/process.h +124 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/ractor.h +6 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/random.h +17 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/range.h +40 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/rational.h +71 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/re.h +28 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/ruby_parser.h +102 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/sanitizers.h +297 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/serial.h +23 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/signal.h +24 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/st.h +11 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/static_assert.h +16 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/string.h +182 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/struct.h +127 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/symbol.h +45 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/thread.h +79 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/time.h +34 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/transcode.h +23 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/util.h +27 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/variable.h +72 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/vm.h +137 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/warnings.h +16 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal.h +108 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/iseq.h +340 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/known_errors.inc +1419 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/method.h +255 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/node.h +111 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/node_name.inc +224 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/optinsn.inc +128 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/optunifs.inc +43 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/parse.h +243 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/parser_bits.h +564 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/parser_node.h +32 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/parser_st.h +162 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/parser_value.h +106 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/ast.h +6245 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/defines.h +206 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/diagnostic.h +433 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/encoding.h +283 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/extension.h +19 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/node.h +150 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/options.h +305 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/pack.h +163 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/parser.h +891 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/prettyprint.h +34 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/prism.h +347 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/regexp.h +33 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/static_literals.h +120 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/util/pm_buffer.h +218 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/util/pm_char.h +205 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/util/pm_constant_pool.h +226 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/util/pm_integer.h +119 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/util/pm_list.h +97 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/util/pm_memchr.h +29 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/util/pm_newline_list.h +102 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/util/pm_string.h +174 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/util/pm_string_list.h +44 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/util/pm_strncasecmp.h +32 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/util/pm_strpbrk.h +46 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/version.h +29 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism_compile.h +88 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/probes_helper.h +42 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/ractor_core.h +393 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/regenc.h +254 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/regint.h +1010 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/regparse.h +371 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/revision.h +5 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/rjit.h +101 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/rjit_c.h +165 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/ruby_assert.h +14 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/ruby_atomic.h +23 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/rubyparser.h +1430 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/shape.h +233 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/siphash.h +48 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/symbol.h +118 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/thread_none.h +21 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/thread_pthread.h +166 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/thread_win32.h +58 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/timev.h +58 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/transcode_data.h +138 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/variable.h +39 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/version.h +69 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/vm.inc +5643 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/vm_call_iseq_optimized.inc +244 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/vm_callinfo.h +605 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/vm_core.h +2236 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/vm_debug.h +124 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/vm_exec.h +199 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/vm_insnhelper.h +272 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/vm_opts.h +67 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/vm_sync.h +137 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/vmtc.inc +253 -0
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/yjit.h +79 -0
- data/lib/debase/ruby_core_source/version.rb +1 -1
- metadata +316 -6
@@ -0,0 +1,277 @@
|
|
1
|
+
#ifndef INTERNAL_CLASS_H /*-*-C-*-vi:se ft=c:*/
|
2
|
+
#define INTERNAL_CLASS_H
|
3
|
+
/**
|
4
|
+
* @author Ruby developers <ruby-core@ruby-lang.org>
|
5
|
+
* @copyright This file is a part of the programming language Ruby.
|
6
|
+
* Permission is hereby granted, to either redistribute and/or
|
7
|
+
* modify this file, provided that the conditions mentioned in the
|
8
|
+
* file COPYING are met. Consult the file for details.
|
9
|
+
* @brief Internal header for Class.
|
10
|
+
*/
|
11
|
+
#include "id.h"
|
12
|
+
#include "id_table.h" /* for struct rb_id_table */
|
13
|
+
#include "internal/serial.h" /* for rb_serial_t */
|
14
|
+
#include "internal/static_assert.h"
|
15
|
+
#include "internal/variable.h" /* for rb_class_ivar_set */
|
16
|
+
#include "ruby/internal/stdbool.h" /* for bool */
|
17
|
+
#include "ruby/intern.h" /* for rb_alloc_func_t */
|
18
|
+
#include "ruby/ruby.h" /* for struct RBasic */
|
19
|
+
#include "shape.h"
|
20
|
+
#include "ruby_assert.h"
|
21
|
+
#include "vm_core.h"
|
22
|
+
#include "vm_sync.h"
|
23
|
+
#include "method.h" /* for rb_cref_t */
|
24
|
+
|
25
|
+
#ifdef RCLASS_SUPER
|
26
|
+
# undef RCLASS_SUPER
|
27
|
+
#endif
|
28
|
+
|
29
|
+
struct rb_subclass_entry {
|
30
|
+
VALUE klass;
|
31
|
+
struct rb_subclass_entry *next;
|
32
|
+
struct rb_subclass_entry *prev;
|
33
|
+
};
|
34
|
+
typedef struct rb_subclass_entry rb_subclass_entry_t;
|
35
|
+
|
36
|
+
struct rb_cvar_class_tbl_entry {
|
37
|
+
uint32_t index;
|
38
|
+
rb_serial_t global_cvar_state;
|
39
|
+
const rb_cref_t * cref;
|
40
|
+
VALUE class_value;
|
41
|
+
};
|
42
|
+
|
43
|
+
struct rb_classext_struct {
|
44
|
+
VALUE *iv_ptr;
|
45
|
+
struct rb_id_table *const_tbl;
|
46
|
+
struct rb_id_table *callable_m_tbl;
|
47
|
+
struct rb_id_table *cc_tbl; /* ID -> [[ci1, cc1], [ci2, cc2] ...] */
|
48
|
+
struct rb_id_table *cvc_tbl;
|
49
|
+
size_t superclass_depth;
|
50
|
+
VALUE *superclasses;
|
51
|
+
struct rb_subclass_entry *subclasses;
|
52
|
+
struct rb_subclass_entry *subclass_entry;
|
53
|
+
/**
|
54
|
+
* In the case that this is an `ICLASS`, `module_subclasses` points to the link
|
55
|
+
* in the module's `subclasses` list that indicates that the klass has been
|
56
|
+
* included. Hopefully that makes sense.
|
57
|
+
*/
|
58
|
+
struct rb_subclass_entry *module_subclass_entry;
|
59
|
+
const VALUE origin_;
|
60
|
+
const VALUE refined_class;
|
61
|
+
union {
|
62
|
+
struct {
|
63
|
+
rb_alloc_func_t allocator;
|
64
|
+
} class;
|
65
|
+
struct {
|
66
|
+
VALUE attached_object;
|
67
|
+
} singleton_class;
|
68
|
+
} as;
|
69
|
+
const VALUE includer;
|
70
|
+
attr_index_t max_iv_count;
|
71
|
+
unsigned char variation_count;
|
72
|
+
bool permanent_classpath : 1;
|
73
|
+
bool cloned : 1;
|
74
|
+
VALUE classpath;
|
75
|
+
};
|
76
|
+
typedef struct rb_classext_struct rb_classext_t;
|
77
|
+
|
78
|
+
STATIC_ASSERT(shape_max_variations, SHAPE_MAX_VARIATIONS < (1 << (sizeof(((rb_classext_t *)0)->variation_count) * CHAR_BIT)));
|
79
|
+
|
80
|
+
struct RClass {
|
81
|
+
struct RBasic basic;
|
82
|
+
VALUE super;
|
83
|
+
struct rb_id_table *m_tbl;
|
84
|
+
};
|
85
|
+
|
86
|
+
// Assert that classes can be embedded in size_pools[2] (which has 160B slot size)
|
87
|
+
STATIC_ASSERT(sizeof_rb_classext_t, sizeof(struct RClass) + sizeof(rb_classext_t) <= 4 * RVALUE_SIZE);
|
88
|
+
|
89
|
+
struct RClass_and_rb_classext_t {
|
90
|
+
struct RClass rclass;
|
91
|
+
rb_classext_t classext;
|
92
|
+
};
|
93
|
+
|
94
|
+
#define RCLASS_EXT(c) (&((struct RClass_and_rb_classext_t*)(c))->classext)
|
95
|
+
#define RCLASS_CONST_TBL(c) (RCLASS_EXT(c)->const_tbl)
|
96
|
+
#define RCLASS_M_TBL(c) (RCLASS(c)->m_tbl)
|
97
|
+
#define RCLASS_IVPTR(c) (RCLASS_EXT(c)->iv_ptr)
|
98
|
+
#define RCLASS_CALLABLE_M_TBL(c) (RCLASS_EXT(c)->callable_m_tbl)
|
99
|
+
#define RCLASS_CC_TBL(c) (RCLASS_EXT(c)->cc_tbl)
|
100
|
+
#define RCLASS_CVC_TBL(c) (RCLASS_EXT(c)->cvc_tbl)
|
101
|
+
#define RCLASS_ORIGIN(c) (RCLASS_EXT(c)->origin_)
|
102
|
+
#define RCLASS_REFINED_CLASS(c) (RCLASS_EXT(c)->refined_class)
|
103
|
+
#define RCLASS_INCLUDER(c) (RCLASS_EXT(c)->includer)
|
104
|
+
#define RCLASS_SUBCLASS_ENTRY(c) (RCLASS_EXT(c)->subclass_entry)
|
105
|
+
#define RCLASS_MODULE_SUBCLASS_ENTRY(c) (RCLASS_EXT(c)->module_subclass_entry)
|
106
|
+
#define RCLASS_SUBCLASSES(c) (RCLASS_EXT(c)->subclasses)
|
107
|
+
#define RCLASS_SUPERCLASS_DEPTH(c) (RCLASS_EXT(c)->superclass_depth)
|
108
|
+
#define RCLASS_SUPERCLASSES(c) (RCLASS_EXT(c)->superclasses)
|
109
|
+
#define RCLASS_ATTACHED_OBJECT(c) (RCLASS_EXT(c)->as.singleton_class.attached_object)
|
110
|
+
|
111
|
+
#define RICLASS_IS_ORIGIN FL_USER0
|
112
|
+
#define RCLASS_SUPERCLASSES_INCLUDE_SELF FL_USER2
|
113
|
+
#define RICLASS_ORIGIN_SHARED_MTBL FL_USER3
|
114
|
+
|
115
|
+
static inline st_table *
|
116
|
+
RCLASS_IV_HASH(VALUE obj)
|
117
|
+
{
|
118
|
+
RUBY_ASSERT(RB_TYPE_P(obj, RUBY_T_CLASS) || RB_TYPE_P(obj, RUBY_T_MODULE));
|
119
|
+
RUBY_ASSERT(rb_shape_obj_too_complex(obj));
|
120
|
+
return (st_table *)RCLASS_IVPTR(obj);
|
121
|
+
}
|
122
|
+
|
123
|
+
static inline void
|
124
|
+
RCLASS_SET_IV_HASH(VALUE obj, const st_table *tbl)
|
125
|
+
{
|
126
|
+
RUBY_ASSERT(RB_TYPE_P(obj, RUBY_T_CLASS) || RB_TYPE_P(obj, RUBY_T_MODULE));
|
127
|
+
RUBY_ASSERT(rb_shape_obj_too_complex(obj));
|
128
|
+
RCLASS_IVPTR(obj) = (VALUE *)tbl;
|
129
|
+
}
|
130
|
+
|
131
|
+
static inline uint32_t
|
132
|
+
RCLASS_IV_COUNT(VALUE obj)
|
133
|
+
{
|
134
|
+
RUBY_ASSERT(RB_TYPE_P(obj, RUBY_T_CLASS) || RB_TYPE_P(obj, RUBY_T_MODULE));
|
135
|
+
if (rb_shape_obj_too_complex(obj)) {
|
136
|
+
uint32_t count;
|
137
|
+
|
138
|
+
// "Too complex" classes could have their IV hash mutated in
|
139
|
+
// parallel, so lets lock around getting the hash size.
|
140
|
+
RB_VM_LOCK_ENTER();
|
141
|
+
{
|
142
|
+
count = (uint32_t)rb_st_table_size(RCLASS_IV_HASH(obj));
|
143
|
+
}
|
144
|
+
RB_VM_LOCK_LEAVE();
|
145
|
+
|
146
|
+
return count;
|
147
|
+
}
|
148
|
+
else {
|
149
|
+
return rb_shape_get_shape_by_id(RCLASS_SHAPE_ID(obj))->next_iv_index;
|
150
|
+
}
|
151
|
+
}
|
152
|
+
|
153
|
+
static inline void
|
154
|
+
RCLASS_SET_M_TBL(VALUE klass, struct rb_id_table *table)
|
155
|
+
{
|
156
|
+
RUBY_ASSERT(!RB_OBJ_PROMOTED(klass));
|
157
|
+
RCLASS_M_TBL(klass) = table;
|
158
|
+
}
|
159
|
+
|
160
|
+
/* class.c */
|
161
|
+
void rb_class_subclass_add(VALUE super, VALUE klass);
|
162
|
+
void rb_class_remove_from_super_subclasses(VALUE);
|
163
|
+
void rb_class_update_superclasses(VALUE);
|
164
|
+
size_t rb_class_superclasses_memsize(VALUE);
|
165
|
+
void rb_class_remove_subclass_head(VALUE);
|
166
|
+
int rb_singleton_class_internal_p(VALUE sklass);
|
167
|
+
VALUE rb_class_boot(VALUE);
|
168
|
+
VALUE rb_class_s_alloc(VALUE klass);
|
169
|
+
VALUE rb_module_s_alloc(VALUE klass);
|
170
|
+
void rb_module_set_initialized(VALUE module);
|
171
|
+
void rb_module_check_initializable(VALUE module);
|
172
|
+
VALUE rb_make_metaclass(VALUE, VALUE);
|
173
|
+
VALUE rb_include_class_new(VALUE, VALUE);
|
174
|
+
void rb_class_foreach_subclass(VALUE klass, void (*f)(VALUE, VALUE), VALUE);
|
175
|
+
void rb_class_detach_subclasses(VALUE);
|
176
|
+
void rb_class_detach_module_subclasses(VALUE);
|
177
|
+
void rb_class_remove_from_module_subclasses(VALUE);
|
178
|
+
VALUE rb_define_class_id_under_no_pin(VALUE outer, ID id, VALUE super);
|
179
|
+
VALUE rb_obj_methods(int argc, const VALUE *argv, VALUE obj);
|
180
|
+
VALUE rb_obj_protected_methods(int argc, const VALUE *argv, VALUE obj);
|
181
|
+
VALUE rb_obj_private_methods(int argc, const VALUE *argv, VALUE obj);
|
182
|
+
VALUE rb_obj_public_methods(int argc, const VALUE *argv, VALUE obj);
|
183
|
+
VALUE rb_class_undefined_instance_methods(VALUE mod);
|
184
|
+
VALUE rb_special_singleton_class(VALUE);
|
185
|
+
VALUE rb_singleton_class_clone_and_attach(VALUE obj, VALUE attach);
|
186
|
+
VALUE rb_singleton_class_get(VALUE obj);
|
187
|
+
void rb_undef_methods_from(VALUE klass, VALUE super);
|
188
|
+
|
189
|
+
static inline void RCLASS_SET_ORIGIN(VALUE klass, VALUE origin);
|
190
|
+
static inline void RICLASS_SET_ORIGIN_SHARED_MTBL(VALUE iclass);
|
191
|
+
static inline VALUE RCLASS_SUPER(VALUE klass);
|
192
|
+
static inline VALUE RCLASS_SET_SUPER(VALUE klass, VALUE super);
|
193
|
+
static inline void RCLASS_SET_INCLUDER(VALUE iclass, VALUE klass);
|
194
|
+
|
195
|
+
VALUE rb_class_inherited(VALUE, VALUE);
|
196
|
+
VALUE rb_keyword_error_new(const char *, VALUE);
|
197
|
+
|
198
|
+
static inline rb_alloc_func_t
|
199
|
+
RCLASS_ALLOCATOR(VALUE klass)
|
200
|
+
{
|
201
|
+
if (FL_TEST_RAW(klass, FL_SINGLETON)) {
|
202
|
+
return 0;
|
203
|
+
}
|
204
|
+
return RCLASS_EXT(klass)->as.class.allocator;
|
205
|
+
}
|
206
|
+
|
207
|
+
static inline void
|
208
|
+
RCLASS_SET_ALLOCATOR(VALUE klass, rb_alloc_func_t allocator)
|
209
|
+
{
|
210
|
+
assert(!FL_TEST(klass, FL_SINGLETON));
|
211
|
+
RCLASS_EXT(klass)->as.class.allocator = allocator;
|
212
|
+
}
|
213
|
+
|
214
|
+
static inline void
|
215
|
+
RCLASS_SET_ORIGIN(VALUE klass, VALUE origin)
|
216
|
+
{
|
217
|
+
RB_OBJ_WRITE(klass, &RCLASS_ORIGIN(klass), origin);
|
218
|
+
if (klass != origin) FL_SET(origin, RICLASS_IS_ORIGIN);
|
219
|
+
}
|
220
|
+
|
221
|
+
static inline void
|
222
|
+
RICLASS_SET_ORIGIN_SHARED_MTBL(VALUE iclass)
|
223
|
+
{
|
224
|
+
FL_SET(iclass, RICLASS_ORIGIN_SHARED_MTBL);
|
225
|
+
}
|
226
|
+
|
227
|
+
static inline bool
|
228
|
+
RICLASS_OWNS_M_TBL_P(VALUE iclass)
|
229
|
+
{
|
230
|
+
return FL_TEST_RAW(iclass, RICLASS_IS_ORIGIN | RICLASS_ORIGIN_SHARED_MTBL) == RICLASS_IS_ORIGIN;
|
231
|
+
}
|
232
|
+
|
233
|
+
static inline void
|
234
|
+
RCLASS_SET_INCLUDER(VALUE iclass, VALUE klass)
|
235
|
+
{
|
236
|
+
RB_OBJ_WRITE(iclass, &RCLASS_INCLUDER(iclass), klass);
|
237
|
+
}
|
238
|
+
|
239
|
+
static inline VALUE
|
240
|
+
RCLASS_SUPER(VALUE klass)
|
241
|
+
{
|
242
|
+
return RCLASS(klass)->super;
|
243
|
+
}
|
244
|
+
|
245
|
+
static inline VALUE
|
246
|
+
RCLASS_SET_SUPER(VALUE klass, VALUE super)
|
247
|
+
{
|
248
|
+
if (super) {
|
249
|
+
rb_class_remove_from_super_subclasses(klass);
|
250
|
+
rb_class_subclass_add(super, klass);
|
251
|
+
}
|
252
|
+
RB_OBJ_WRITE(klass, &RCLASS(klass)->super, super);
|
253
|
+
rb_class_update_superclasses(klass);
|
254
|
+
return super;
|
255
|
+
}
|
256
|
+
|
257
|
+
static inline void
|
258
|
+
RCLASS_SET_CLASSPATH(VALUE klass, VALUE classpath, bool permanent)
|
259
|
+
{
|
260
|
+
assert(BUILTIN_TYPE(klass) == T_CLASS || BUILTIN_TYPE(klass) == T_MODULE);
|
261
|
+
assert(classpath == 0 || BUILTIN_TYPE(classpath) == T_STRING);
|
262
|
+
|
263
|
+
RB_OBJ_WRITE(klass, &(RCLASS_EXT(klass)->classpath), classpath);
|
264
|
+
RCLASS_EXT(klass)->permanent_classpath = permanent;
|
265
|
+
}
|
266
|
+
|
267
|
+
static inline VALUE
|
268
|
+
RCLASS_SET_ATTACHED_OBJECT(VALUE klass, VALUE attached_object)
|
269
|
+
{
|
270
|
+
assert(BUILTIN_TYPE(klass) == T_CLASS);
|
271
|
+
assert(FL_TEST_RAW(klass, FL_SINGLETON));
|
272
|
+
|
273
|
+
RB_OBJ_WRITE(klass, &RCLASS_EXT(klass)->as.singleton_class.attached_object, attached_object);
|
274
|
+
return attached_object;
|
275
|
+
}
|
276
|
+
|
277
|
+
#endif /* INTERNAL_CLASS_H */
|
@@ -0,0 +1,65 @@
|
|
1
|
+
#ifndef INTERNAL_CMDLINEOPT_H /*-*-C-*-vi:se ft=c:*/
|
2
|
+
#define INTERNAL_CMDLINEOPT_H
|
3
|
+
|
4
|
+
#include "rjit.h"
|
5
|
+
#include "yjit.h"
|
6
|
+
|
7
|
+
typedef struct {
|
8
|
+
unsigned int mask;
|
9
|
+
unsigned int set;
|
10
|
+
} ruby_features_t;
|
11
|
+
|
12
|
+
typedef struct ruby_cmdline_options {
|
13
|
+
const char *script;
|
14
|
+
VALUE script_name;
|
15
|
+
VALUE e_script;
|
16
|
+
struct {
|
17
|
+
struct {
|
18
|
+
VALUE name;
|
19
|
+
int index;
|
20
|
+
} enc;
|
21
|
+
} src, ext, intern;
|
22
|
+
VALUE req_list;
|
23
|
+
ruby_features_t features;
|
24
|
+
ruby_features_t warn;
|
25
|
+
unsigned int dump;
|
26
|
+
long backtrace_length_limit;
|
27
|
+
#if USE_RJIT
|
28
|
+
struct rb_rjit_options rjit;
|
29
|
+
#endif
|
30
|
+
|
31
|
+
const char *crash_report;
|
32
|
+
|
33
|
+
signed int sflag: 2;
|
34
|
+
unsigned int xflag: 1;
|
35
|
+
unsigned int warning: 1;
|
36
|
+
unsigned int verbose: 1;
|
37
|
+
unsigned int do_loop: 1;
|
38
|
+
unsigned int do_print: 1;
|
39
|
+
unsigned int do_line: 1;
|
40
|
+
unsigned int do_split: 1;
|
41
|
+
unsigned int do_search: 1;
|
42
|
+
unsigned int setids: 2;
|
43
|
+
#if USE_YJIT
|
44
|
+
unsigned int yjit: 1;
|
45
|
+
#endif
|
46
|
+
} ruby_cmdline_options_t;
|
47
|
+
|
48
|
+
struct ruby_opt_message {
|
49
|
+
const char *str;
|
50
|
+
unsigned short namelen, secondlen;
|
51
|
+
};
|
52
|
+
|
53
|
+
#define RUBY_OPT_MESSAGE(shortopt, longopt, desc) { \
|
54
|
+
shortopt " " longopt " " desc, \
|
55
|
+
(unsigned short)sizeof(shortopt), \
|
56
|
+
(unsigned short)sizeof(longopt), \
|
57
|
+
}
|
58
|
+
|
59
|
+
#define opt_match(s, l, name) \
|
60
|
+
((((l) > rb_strlen_lit(name)) ? (s)[rb_strlen_lit(name)] == '=' : \
|
61
|
+
(l) == rb_strlen_lit(name)) && \
|
62
|
+
memcmp((s), name, rb_strlen_lit(name)) == 0 && \
|
63
|
+
(((s) += rb_strlen_lit(name)), 1))
|
64
|
+
|
65
|
+
#endif
|
@@ -0,0 +1,29 @@
|
|
1
|
+
#ifndef INTERNAL_COMPAR_H /*-*-C-*-vi:se ft=c:*/
|
2
|
+
#define INTERNAL_COMPAR_H
|
3
|
+
/**
|
4
|
+
* @author Ruby developers <ruby-core@ruby-lang.org>
|
5
|
+
* @copyright This file is a part of the programming language Ruby.
|
6
|
+
* Permission is hereby granted, to either redistribute and/or
|
7
|
+
* modify this file, provided that the conditions mentioned in the
|
8
|
+
* file COPYING are met. Consult the file for details.
|
9
|
+
* @brief Internal header for Comparable.
|
10
|
+
*/
|
11
|
+
#include "internal/basic_operators.h"
|
12
|
+
|
13
|
+
#define STRING_P(s) (RB_TYPE_P((s), T_STRING) && CLASS_OF(s) == rb_cString)
|
14
|
+
|
15
|
+
#define CMP_OPTIMIZABLE(type) BASIC_OP_UNREDEFINED_P(BOP_CMP, type##_REDEFINED_OP_FLAG)
|
16
|
+
|
17
|
+
#define OPTIMIZED_CMP(a, b) \
|
18
|
+
((FIXNUM_P(a) && FIXNUM_P(b) && CMP_OPTIMIZABLE(INTEGER)) ? \
|
19
|
+
(((long)a > (long)b) ? 1 : ((long)a < (long)b) ? -1 : 0) : \
|
20
|
+
(STRING_P(a) && STRING_P(b) && CMP_OPTIMIZABLE(STRING)) ? \
|
21
|
+
rb_str_cmp(a, b) : \
|
22
|
+
(RB_FLOAT_TYPE_P(a) && RB_FLOAT_TYPE_P(b) && CMP_OPTIMIZABLE(FLOAT)) ? \
|
23
|
+
rb_float_cmp(a, b) : \
|
24
|
+
rb_cmpint(rb_funcallv(a, id_cmp, 1, &b), a, b))
|
25
|
+
|
26
|
+
/* compar.c */
|
27
|
+
VALUE rb_invcmp(VALUE, VALUE);
|
28
|
+
|
29
|
+
#endif /* INTERNAL_COMPAR_H */
|
@@ -0,0 +1,34 @@
|
|
1
|
+
#ifndef INTERNAL_COMPILE_H /*-*-C-*-vi:se ft=c:*/
|
2
|
+
#define INTERNAL_COMPILE_H
|
3
|
+
/**
|
4
|
+
* @author Ruby developers <ruby-core@ruby-lang.org>
|
5
|
+
* @copyright This file is a part of the programming language Ruby.
|
6
|
+
* Permission is hereby granted, to either redistribute and/or
|
7
|
+
* modify this file, provided that the conditions mentioned in the
|
8
|
+
* file COPYING are met. Consult the file for details.
|
9
|
+
* @brief Internal header for the compiler.
|
10
|
+
*/
|
11
|
+
#include "ruby/internal/config.h"
|
12
|
+
#include <stddef.h> /* for size_t */
|
13
|
+
#include "ruby/ruby.h" /* for rb_event_flag_t */
|
14
|
+
|
15
|
+
struct rb_iseq_struct; /* in vm_core.h */
|
16
|
+
|
17
|
+
/* compile.c */
|
18
|
+
int rb_dvar_defined(ID, const struct rb_iseq_struct *);
|
19
|
+
int rb_local_defined(ID, const struct rb_iseq_struct *);
|
20
|
+
int rb_insn_len(VALUE insn);
|
21
|
+
const char *rb_insns_name(int i);
|
22
|
+
VALUE rb_insns_name_array(void);
|
23
|
+
int rb_iseq_cdhash_cmp(VALUE val, VALUE lit);
|
24
|
+
st_index_t rb_iseq_cdhash_hash(VALUE a);
|
25
|
+
|
26
|
+
/* iseq.c */
|
27
|
+
int rb_vm_insn_addr2insn(const void *);
|
28
|
+
int rb_vm_insn_decode(const VALUE encoded);
|
29
|
+
extern bool ruby_vm_keep_script_lines;
|
30
|
+
|
31
|
+
/* iseq.c (export) */
|
32
|
+
rb_event_flag_t rb_iseq_event_flags(const struct rb_iseq_struct *iseq, size_t pos);
|
33
|
+
|
34
|
+
#endif /* INTERNAL_COMPILE_H */
|
@@ -0,0 +1,107 @@
|
|
1
|
+
#ifndef INTERNAL_COMPILERS_H /*-*-C-*-vi:se ft=c:*/
|
2
|
+
#define INTERNAL_COMPILERS_H
|
3
|
+
/**
|
4
|
+
* @author Ruby developers <ruby-core@ruby-lang.org>
|
5
|
+
* @copyright This file is a part of the programming language Ruby.
|
6
|
+
* Permission is hereby granted, to either redistribute and/or
|
7
|
+
* modify this file, provided that the conditions mentioned in the
|
8
|
+
* file COPYING are met. Consult the file for details.
|
9
|
+
* @brief Internal header absorbing C compiler differences.
|
10
|
+
*/
|
11
|
+
#include "ruby/internal/compiler_since.h"
|
12
|
+
#include "ruby/internal/has/attribute.h"
|
13
|
+
#include "ruby/internal/has/builtin.h"
|
14
|
+
#include "ruby/internal/has/c_attribute.h"
|
15
|
+
#include "ruby/internal/has/declspec_attribute.h"
|
16
|
+
#include "ruby/internal/has/extension.h"
|
17
|
+
#include "ruby/internal/has/feature.h"
|
18
|
+
#include "ruby/internal/has/warning.h"
|
19
|
+
#include "ruby/backward/2/gcc_version_since.h"
|
20
|
+
|
21
|
+
#define MSC_VERSION_SINCE(_) RBIMPL_COMPILER_SINCE(MSVC, (_) / 100, (_) % 100, 0)
|
22
|
+
#define MSC_VERSION_BEFORE(_) RBIMPL_COMPILER_BEFORE(MSVC, (_) / 100, (_) % 100, 0)
|
23
|
+
|
24
|
+
#ifndef __has_attribute
|
25
|
+
# define __has_attribute(...) RBIMPL_HAS_ATTRIBUTE(__VA_ARGS__)
|
26
|
+
#endif
|
27
|
+
|
28
|
+
#ifndef __has_c_attribute
|
29
|
+
# /* As of writing everything that lacks __has_c_attribute also completely
|
30
|
+
# * lacks C2x attributes as well. Might change in future? */
|
31
|
+
# define __has_c_attribute(...) 0
|
32
|
+
#endif
|
33
|
+
|
34
|
+
#ifndef __has_declspec_attribute
|
35
|
+
# define __has_declspec_attribute(...) RBIMPL_HAS_DECLSPEC_ATTRIBUTE(__VA_ARGS__)
|
36
|
+
#endif
|
37
|
+
|
38
|
+
#ifndef __has_builtin
|
39
|
+
# define __has_builtin(...) RBIMPL_HAS_BUILTIN(__VA_ARGS__)
|
40
|
+
#endif
|
41
|
+
|
42
|
+
#ifndef __has_feature
|
43
|
+
# define __has_feature(...) RBIMPL_HAS_FEATURE(__VA_ARGS__)
|
44
|
+
#endif
|
45
|
+
|
46
|
+
#ifndef __has_extension
|
47
|
+
# define __has_extension(...) RBIMPL_HAS_EXTENSION(__VA_ARGS__)
|
48
|
+
#endif
|
49
|
+
|
50
|
+
#ifndef __has_warning
|
51
|
+
# define __has_warning(...) RBIMPL_HAS_WARNING(__VA_ARGS__)
|
52
|
+
#endif
|
53
|
+
|
54
|
+
#ifndef __GNUC__
|
55
|
+
# define __extension__ /* void */
|
56
|
+
#endif
|
57
|
+
|
58
|
+
#ifndef MAYBE_UNUSED
|
59
|
+
# define MAYBE_UNUSED(x) x
|
60
|
+
#endif
|
61
|
+
|
62
|
+
#ifndef WARN_UNUSED_RESULT
|
63
|
+
# define WARN_UNUSED_RESULT(x) x
|
64
|
+
#endif
|
65
|
+
|
66
|
+
#define RB_OBJ_BUILTIN_TYPE(obj) rb_obj_builtin_type(obj)
|
67
|
+
#define OBJ_BUILTIN_TYPE(obj) RB_OBJ_BUILTIN_TYPE(obj)
|
68
|
+
#ifdef __GNUC__
|
69
|
+
#define rb_obj_builtin_type(obj) \
|
70
|
+
__extension__({ \
|
71
|
+
VALUE arg_obj = (obj); \
|
72
|
+
RB_SPECIAL_CONST_P(arg_obj) ? -1 : \
|
73
|
+
(int)RB_BUILTIN_TYPE(arg_obj); \
|
74
|
+
})
|
75
|
+
#else
|
76
|
+
# include "ruby/ruby.h"
|
77
|
+
static inline int
|
78
|
+
rb_obj_builtin_type(VALUE obj)
|
79
|
+
{
|
80
|
+
return RB_SPECIAL_CONST_P(obj) ? -1 :
|
81
|
+
(int)RB_BUILTIN_TYPE(obj);
|
82
|
+
}
|
83
|
+
#endif
|
84
|
+
|
85
|
+
/* A macro for defining a flexible array, like: VALUE ary[FLEX_ARY_LEN]; */
|
86
|
+
#if defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 199901L)
|
87
|
+
# define FLEX_ARY_LEN /* VALUE ary[]; */
|
88
|
+
#elif defined(__GNUC__) && !defined(__STRICT_ANSI__)
|
89
|
+
# define FLEX_ARY_LEN 0 /* VALUE ary[0]; */
|
90
|
+
#else
|
91
|
+
# define FLEX_ARY_LEN 1 /* VALUE ary[1]; */
|
92
|
+
#endif
|
93
|
+
|
94
|
+
/*
|
95
|
+
* For declaring bitfields out of non-unsigned int types:
|
96
|
+
* struct date {
|
97
|
+
* BITFIELD(enum months, month, 4);
|
98
|
+
* ...
|
99
|
+
* };
|
100
|
+
*/
|
101
|
+
#if defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 199901L)
|
102
|
+
# define BITFIELD(type, name, size) type name : size
|
103
|
+
#else
|
104
|
+
# define BITFIELD(type, name, size) unsigned int name : size
|
105
|
+
#endif
|
106
|
+
|
107
|
+
#endif /* INTERNAL_COMPILERS_H */
|
@@ -0,0 +1,29 @@
|
|
1
|
+
#ifndef INTERNAL_COMPLEX_H /*-*-C-*-vi:se ft=c:*/
|
2
|
+
#define INTERNAL_COMPLEX_H
|
3
|
+
/**
|
4
|
+
* @author Ruby developers <ruby-core@ruby-lang.org>
|
5
|
+
* @copyright This file is a part of the programming language Ruby.
|
6
|
+
* Permission is hereby granted, to either redistribute and/or
|
7
|
+
* modify this file, provided that the conditions mentioned in the
|
8
|
+
* file COPYING are met. Consult the file for details.
|
9
|
+
* @brief Internal header for Complex.
|
10
|
+
*/
|
11
|
+
#include "ruby/internal/value.h" /* for struct RBasic */
|
12
|
+
|
13
|
+
struct RComplex {
|
14
|
+
struct RBasic basic;
|
15
|
+
VALUE real;
|
16
|
+
VALUE imag;
|
17
|
+
};
|
18
|
+
|
19
|
+
#define RCOMPLEX(obj) ((struct RComplex *)(obj))
|
20
|
+
|
21
|
+
/* shortcut macro for internal only */
|
22
|
+
#define RCOMPLEX_SET_REAL(cmp, r) RB_OBJ_WRITE((cmp), &RCOMPLEX(cmp)->real, (r))
|
23
|
+
#define RCOMPLEX_SET_IMAG(cmp, i) RB_OBJ_WRITE((cmp), &RCOMPLEX(cmp)->imag, (i))
|
24
|
+
|
25
|
+
/* complex.c */
|
26
|
+
VALUE rb_dbl_complex_new_polar_pi(double abs, double ang);
|
27
|
+
st_index_t rb_complex_hash(VALUE comp);
|
28
|
+
|
29
|
+
#endif /* INTERNAL_COMPLEX_H */
|
@@ -0,0 +1,35 @@
|
|
1
|
+
#ifndef INTERNAL_CONT_H /*-*-C-*-vi:se ft=c:*/
|
2
|
+
#define INTERNAL_CONT_H
|
3
|
+
/**
|
4
|
+
* @author Ruby developers <ruby-core@ruby-lang.org>
|
5
|
+
* @copyright This file is a part of the programming language Ruby.
|
6
|
+
* Permission is hereby granted, to either redistribute and/or
|
7
|
+
* modify this file, provided that the conditions mentioned in the
|
8
|
+
* file COPYING are met. Consult the file for details.
|
9
|
+
* @brief Internal header for Fiber.
|
10
|
+
*/
|
11
|
+
#include "ruby/ruby.h" /* for VALUE */
|
12
|
+
#include "iseq.h"
|
13
|
+
|
14
|
+
struct rb_thread_struct; /* in vm_core.h */
|
15
|
+
struct rb_fiber_struct; /* in cont.c */
|
16
|
+
struct rb_execution_context_struct; /* in vm_core.c */
|
17
|
+
|
18
|
+
/* cont.c */
|
19
|
+
void rb_fiber_reset_root_local_storage(struct rb_thread_struct *);
|
20
|
+
void ruby_register_rollback_func_for_ensure(VALUE (*ensure_func)(VALUE), VALUE (*rollback_func)(VALUE));
|
21
|
+
void rb_jit_cont_init(void);
|
22
|
+
void rb_jit_cont_each_iseq(rb_iseq_callback callback, void *data);
|
23
|
+
void rb_jit_cont_finish(void);
|
24
|
+
|
25
|
+
/* vm.c */
|
26
|
+
void rb_free_shared_fiber_pool(void);
|
27
|
+
|
28
|
+
// Copy locals from the current execution to the specified fiber.
|
29
|
+
VALUE rb_fiber_inherit_storage(struct rb_execution_context_struct *ec, struct rb_fiber_struct *fiber);
|
30
|
+
|
31
|
+
VALUE rb_fiberptr_self(struct rb_fiber_struct *fiber);
|
32
|
+
unsigned int rb_fiberptr_blocking(struct rb_fiber_struct *fiber);
|
33
|
+
struct rb_execution_context_struct * rb_fiberptr_get_ec(struct rb_fiber_struct *fiber);
|
34
|
+
|
35
|
+
#endif /* INTERNAL_CONT_H */
|
@@ -0,0 +1,16 @@
|
|
1
|
+
#ifndef INTERNAL_DIR_H /*-*-C-*-vi:se ft=c:*/
|
2
|
+
#define INTERNAL_DIR_H
|
3
|
+
/**
|
4
|
+
* @author Ruby developers <ruby-core@ruby-lang.org>
|
5
|
+
* @copyright This file is a part of the programming language Ruby.
|
6
|
+
* Permission is hereby granted, to either redistribute and/or
|
7
|
+
* modify this file, provided that the conditions mentioned in the
|
8
|
+
* file COPYING are met. Consult the file for details.
|
9
|
+
* @brief Internal header for Dir.
|
10
|
+
*/
|
11
|
+
#include "ruby/ruby.h" /* for VALUE */
|
12
|
+
|
13
|
+
/* dir.c */
|
14
|
+
VALUE rb_dir_getwd_ospath(void);
|
15
|
+
|
16
|
+
#endif /* INTERNAL_DIR_H */
|
@@ -0,0 +1,19 @@
|
|
1
|
+
#ifndef INTERNAL_ENC_H /*-*-C-*-vi:se ft=c:*/
|
2
|
+
#define INTERNAL_ENC_H
|
3
|
+
/**
|
4
|
+
* @author Ruby developers <ruby-core@ruby-lang.org>
|
5
|
+
* @copyright This file is a part of the programming language Ruby.
|
6
|
+
* Permission is hereby granted, to either redistribute and/or
|
7
|
+
* modify this file, provided that the conditions mentioned in the
|
8
|
+
* file COPYING are met. Consult the file for details.
|
9
|
+
* @brief Internal header for Encoding.
|
10
|
+
*/
|
11
|
+
#include "ruby/encoding.h" /* for rb_encoding */
|
12
|
+
|
13
|
+
/* us_ascii.c */
|
14
|
+
extern rb_encoding OnigEncodingUS_ASCII;
|
15
|
+
|
16
|
+
/* utf_8.c */
|
17
|
+
extern rb_encoding OnigEncodingUTF_8;
|
18
|
+
|
19
|
+
#endif /* INTERNAL_ENC_H */
|
@@ -0,0 +1,35 @@
|
|
1
|
+
#ifndef INTERNAL_ENCODING_H /*-*-C-*-vi:se ft=c:*/
|
2
|
+
#define INTERNAL_ENCODING_H
|
3
|
+
/**
|
4
|
+
* @author Ruby developers <ruby-core@ruby-lang.org>
|
5
|
+
* @copyright This file is a part of the programming language Ruby.
|
6
|
+
* Permission is hereby granted, to either redistribute and/or
|
7
|
+
* modify this file, provided that the conditions mentioned in the
|
8
|
+
* file COPYING are met. Consult the file for details.
|
9
|
+
* @brief Internal header for Encoding.
|
10
|
+
*/
|
11
|
+
#include "ruby/ruby.h" /* for ID */
|
12
|
+
#include "ruby/encoding.h" /* for rb_encoding */
|
13
|
+
|
14
|
+
#define rb_enc_autoload_p(enc) (!rb_enc_mbmaxlen(enc))
|
15
|
+
#define rb_is_usascii_enc(enc) ((enc) == rb_usascii_encoding())
|
16
|
+
#define rb_is_ascii8bit_enc(enc) ((enc) == rb_ascii8bit_encoding())
|
17
|
+
#define rb_is_locale_enc(enc) ((enc) == rb_locale_encoding())
|
18
|
+
|
19
|
+
/* encoding.c */
|
20
|
+
ID rb_id_encoding(void);
|
21
|
+
rb_encoding *rb_enc_get_from_index(int index);
|
22
|
+
rb_encoding *rb_enc_check_str(VALUE str1, VALUE str2);
|
23
|
+
int rb_encdb_replicate(const char *alias, const char *orig);
|
24
|
+
int rb_encdb_alias(const char *alias, const char *orig);
|
25
|
+
int rb_enc_autoload(rb_encoding *enc);
|
26
|
+
int rb_encdb_dummy(const char *name);
|
27
|
+
void rb_encdb_declare(const char *name);
|
28
|
+
void rb_enc_set_base(const char *name, const char *orig);
|
29
|
+
int rb_enc_set_dummy(int index);
|
30
|
+
PUREFUNC(int rb_data_is_encoding(VALUE obj));
|
31
|
+
|
32
|
+
/* vm.c */
|
33
|
+
void rb_free_global_enc_table(void);
|
34
|
+
|
35
|
+
#endif /* INTERNAL_ENCODING_H */
|
@@ -0,0 +1,18 @@
|
|
1
|
+
#ifndef INTERNAL_ENUM_H /*-*-C-*-vi:se ft=c:*/
|
2
|
+
#define INTERNAL_ENUM_H
|
3
|
+
/**
|
4
|
+
* @author Ruby developers <ruby-core@ruby-lang.org>
|
5
|
+
* @copyright This file is a part of the programming language Ruby.
|
6
|
+
* Permission is hereby granted, to either redistribute and/or
|
7
|
+
* modify this file, provided that the conditions mentioned in the
|
8
|
+
* file COPYING are met. Consult the file for details.
|
9
|
+
* @brief Internal header for Enumerable.
|
10
|
+
*/
|
11
|
+
#include "ruby/ruby.h" /* for VALUE */
|
12
|
+
|
13
|
+
/* enum.c */
|
14
|
+
extern VALUE rb_cArithSeq;
|
15
|
+
VALUE rb_f_send(int argc, VALUE *argv, VALUE recv);
|
16
|
+
VALUE rb_nmin_run(VALUE obj, VALUE num, int by, int rev, int ary);
|
17
|
+
|
18
|
+
#endif /* INTERNAL_ENUM_H */
|