datadog-ruby_core_source 3.4.1 → 3.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/id.h +357 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/id_table.h +15 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/array.h +2 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/internal/basic_operators.h +66 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/internal/bignum.h +256 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/internal/bits.h +647 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/internal/box.h +83 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/internal/class.h +806 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/cmdlineopt.h +3 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/internal/concurrent_set.h +21 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/internal/cont.h +34 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/encoding.h +2 -1
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/error.h +7 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/internal/eval.h +43 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/internal/gc.h +360 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/hash.h +1 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/imemo.h +87 -22
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/inits.h +4 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/io.h +25 -5
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/load.h +2 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/internal/numeric.h +323 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/object.h +1 -1
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/re.h +5 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/sanitizers.h +16 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/internal/set_table.h +70 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/signal.h +1 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/st.h +1 -1
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/string.h +4 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/struct.h +41 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/symbol.h +4 -5
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/internal/thread.h +112 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/internal/time.h +34 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/variable.h +13 -9
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/internal/vm.h +138 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal.h +0 -3
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/iseq.h +359 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/method.h +276 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/prism/ast.h +8254 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/diagnostic.h +7 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/extension.h +1 -1
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/prism/options.h +488 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/parser.h +3 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/prism/prism.h +408 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/regexp.h +2 -2
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/util/pm_buffer.h +8 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/util/pm_integer.h +4 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/util/pm_list.h +6 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/util/pm_string.h +12 -2
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/version.h +2 -2
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism_compile.h +1 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/ractor_core.h +63 -114
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/ruby_atomic.h +73 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/rubyparser.h +1393 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/shape.h +464 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/thread_pthread.h +177 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/vm_core.h +2406 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-p0/vm_debug.h +124 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/ccan/build_assert/build_assert.h +40 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/ccan/check_type/check_type.h +63 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/ccan/container_of/container_of.h +142 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/ccan/list/list.h +791 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/ccan/str/str.h +17 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/id.h +7 -5
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/id_table.h +54 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/array.h +154 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/internal/bignum.h +1 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/box.h +81 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/class.h +805 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/cmdlineopt.h +64 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/compar.h +29 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/compile.h +34 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/compilers.h +107 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/complex.h +29 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/concurrent_set.h +21 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/dir.h +16 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/enc.h +19 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/encoding.h +39 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/enum.h +18 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/enumerator.h +21 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/error.h +251 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/internal/eval.h +8 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/file.h +38 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/fixnum.h +185 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/internal/gc.h +25 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/hash.h +194 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/imemo.h +322 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/inits.h +51 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/io.h +163 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/load.h +20 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/loadpath.h +16 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/math.h +23 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/missing.h +19 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/internal/numeric.h +1 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/object.h +63 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/parse.h +131 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/proc.h +30 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/process.h +124 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/ractor.h +10 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/random.h +17 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/range.h +40 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/rational.h +71 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/re.h +33 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/ruby_parser.h +102 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/sanitizers.h +346 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/serial.h +23 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/set_table.h +70 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/signal.h +25 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/st.h +11 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/static_assert.h +16 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/string.h +203 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/struct.h +160 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/symbol.h +46 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/internal/thread.h +14 -10
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/transcode.h +23 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/util.h +27 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/variable.h +74 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/internal/vm.h +3 -4
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal/warnings.h +16 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/internal.h +105 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/iseq.h +7 -1
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/method.h +14 -1
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/node.h +122 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/parser_st.h +162 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/parser_value.h +106 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/prism/ast.h +322 -53
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/defines.h +260 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/diagnostic.h +458 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/encoding.h +283 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/extension.h +19 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/node.h +129 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/prism/options.h +46 -3
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/pack.h +163 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/parser.h +936 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/prettyprint.h +34 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/prism/prism.h +39 -14
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/regexp.h +43 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/static_literals.h +121 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/util/pm_buffer.h +236 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/util/pm_char.h +204 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/util/pm_constant_pool.h +218 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/util/pm_integer.h +130 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/util/pm_list.h +103 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/util/pm_memchr.h +29 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/util/pm_newline_list.h +113 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/util/pm_string.h +200 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/util/pm_strncasecmp.h +32 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/util/pm_strpbrk.h +46 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism/version.h +29 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/prism_compile.h +106 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/ractor_core.h +306 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/ruby_assert.h +14 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/ruby_atomic.h +66 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/rubyparser.h +15 -1
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/shape.h +444 -0
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/thread_none.h +21 -0
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/thread_pthread.h +10 -2
- data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/vm_core.h +160 -45
- data/lib/datadog/ruby_core_source/ruby-4.0.0-preview2/vm_opts.h +67 -0
- data/lib/datadog/ruby_core_source/version.rb +1 -1
- data/lib/datadog/ruby_core_source.rb +1 -1
- metadata +214 -106
- data/CHANGELOG.datadog.md +0 -19
- data/lib/datadog/ruby_core_source/ruby-3.5.0-preview1/internal/class.h +0 -283
- data/lib/datadog/ruby_core_source/ruby-3.5.0-preview1/ruby_atomic.h +0 -23
- data/lib/datadog/ruby_core_source/ruby-3.5.0-preview1/shape.h +0 -234
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/ccan/build_assert/build_assert.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/ccan/check_type/check_type.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/ccan/container_of/container_of.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/ccan/list/list.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/ccan/str/str.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/compar.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/compile.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/compilers.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/complex.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/dir.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/enc.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/enum.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/enumerator.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/file.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/fixnum.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/loadpath.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/math.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/missing.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/parse.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/proc.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/process.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/ractor.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/random.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/range.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/rational.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/ruby_parser.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/serial.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/static_assert.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/transcode.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/util.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/internal/warnings.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/node.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/parser_st.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/parser_value.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/defines.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/encoding.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/node.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/pack.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/prettyprint.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/static_literals.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/util/pm_char.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/util/pm_constant_pool.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/util/pm_memchr.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/util/pm_newline_list.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/util/pm_strncasecmp.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/prism/util/pm_strpbrk.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/ruby_assert.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/thread_none.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-p0}/vm_opts.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/internal/basic_operators.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/internal/bits.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/internal/cont.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/internal/time.h +0 -0
- /data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/vm_debug.h +0 -0
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
#ifndef INTERNAL_STRUCT_H /*-*-C-*-vi:se ft=c:*/
|
|
2
|
+
#define INTERNAL_STRUCT_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 Struct.
|
|
10
|
+
*/
|
|
11
|
+
#include "ruby/internal/stdbool.h" /* for bool */
|
|
12
|
+
#include "ruby/ruby.h" /* for struct RBasic */
|
|
13
|
+
|
|
14
|
+
/* Flags of RStruct
|
|
15
|
+
*
|
|
16
|
+
* 1-7: RSTRUCT_EMBED_LEN
|
|
17
|
+
* If non-zero, the struct is embedded (its contents follow the
|
|
18
|
+
* header, rather than being on a separately allocated buffer) and
|
|
19
|
+
* these bits are the length of the Struct.
|
|
20
|
+
* 8: RSTRUCT_GEN_FIELDS
|
|
21
|
+
* The struct is embedded and has no space left to store the
|
|
22
|
+
* IMEMO/fields reference. Any ivar this struct may have will be in
|
|
23
|
+
* the generic_fields_tbl. This flag doesn't imply the struct has
|
|
24
|
+
* ivars.
|
|
25
|
+
*/
|
|
26
|
+
enum {
|
|
27
|
+
RSTRUCT_EMBED_LEN_MASK = RUBY_FL_USER7 | RUBY_FL_USER6 | RUBY_FL_USER5 | RUBY_FL_USER4 |
|
|
28
|
+
RUBY_FL_USER3 | RUBY_FL_USER2 | RUBY_FL_USER1,
|
|
29
|
+
RSTRUCT_EMBED_LEN_SHIFT = (RUBY_FL_USHIFT+1),
|
|
30
|
+
RSTRUCT_GEN_FIELDS = RUBY_FL_USER8,
|
|
31
|
+
};
|
|
32
|
+
|
|
33
|
+
struct RStruct {
|
|
34
|
+
struct RBasic basic;
|
|
35
|
+
union {
|
|
36
|
+
struct {
|
|
37
|
+
long len;
|
|
38
|
+
const VALUE *ptr;
|
|
39
|
+
VALUE fields_obj;
|
|
40
|
+
} heap;
|
|
41
|
+
/* This is a length 1 array because:
|
|
42
|
+
* 1. GCC has a bug that does not optimize C flexible array members
|
|
43
|
+
* (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102452)
|
|
44
|
+
* 2. Zero length arrays are not supported by all compilers
|
|
45
|
+
*/
|
|
46
|
+
const VALUE ary[1];
|
|
47
|
+
} as;
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
#define RSTRUCT(obj) ((struct RStruct *)(obj))
|
|
51
|
+
|
|
52
|
+
#ifdef RSTRUCT_LEN
|
|
53
|
+
# undef RSTRUCT_LEN
|
|
54
|
+
#endif
|
|
55
|
+
|
|
56
|
+
#ifdef RSTRUCT_PTR
|
|
57
|
+
# undef RSTRUCT_PTR
|
|
58
|
+
#endif
|
|
59
|
+
|
|
60
|
+
#ifdef RSTRUCT_SET
|
|
61
|
+
# undef RSTRUCT_SET
|
|
62
|
+
#endif
|
|
63
|
+
|
|
64
|
+
#ifdef RSTRUCT_GET
|
|
65
|
+
# undef RSTRUCT_GET
|
|
66
|
+
#endif
|
|
67
|
+
|
|
68
|
+
#define RSTRUCT_LEN internal_RSTRUCT_LEN
|
|
69
|
+
#define RSTRUCT_SET internal_RSTRUCT_SET
|
|
70
|
+
#define RSTRUCT_GET internal_RSTRUCT_GET
|
|
71
|
+
|
|
72
|
+
/* struct.c */
|
|
73
|
+
VALUE rb_struct_init_copy(VALUE copy, VALUE s);
|
|
74
|
+
VALUE rb_struct_lookup(VALUE s, VALUE idx);
|
|
75
|
+
VALUE rb_struct_s_keyword_init(VALUE klass);
|
|
76
|
+
static inline long RSTRUCT_EMBED_LEN(VALUE st);
|
|
77
|
+
static inline long RSTRUCT_LEN(VALUE st);
|
|
78
|
+
static inline int RSTRUCT_LENINT(VALUE st);
|
|
79
|
+
static inline const VALUE *RSTRUCT_CONST_PTR(VALUE st);
|
|
80
|
+
static inline void RSTRUCT_SET(VALUE st, long k, VALUE v);
|
|
81
|
+
static inline VALUE RSTRUCT_GET(VALUE st, long k);
|
|
82
|
+
|
|
83
|
+
static inline long
|
|
84
|
+
RSTRUCT_EMBED_LEN(VALUE st)
|
|
85
|
+
{
|
|
86
|
+
long ret = FL_TEST_RAW(st, RSTRUCT_EMBED_LEN_MASK);
|
|
87
|
+
ret >>= RSTRUCT_EMBED_LEN_SHIFT;
|
|
88
|
+
return ret;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
static inline long
|
|
92
|
+
RSTRUCT_LEN(VALUE st)
|
|
93
|
+
{
|
|
94
|
+
if (FL_TEST_RAW(st, RSTRUCT_EMBED_LEN_MASK)) {
|
|
95
|
+
return RSTRUCT_EMBED_LEN(st);
|
|
96
|
+
}
|
|
97
|
+
else {
|
|
98
|
+
return RSTRUCT(st)->as.heap.len;
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
static inline int
|
|
103
|
+
RSTRUCT_LENINT(VALUE st)
|
|
104
|
+
{
|
|
105
|
+
return rb_long2int(RSTRUCT_LEN(st));
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
static inline const VALUE *
|
|
109
|
+
RSTRUCT_CONST_PTR(VALUE st)
|
|
110
|
+
{
|
|
111
|
+
const struct RStruct *p = RSTRUCT(st);
|
|
112
|
+
|
|
113
|
+
if (FL_TEST_RAW(st, RSTRUCT_EMBED_LEN_MASK)) {
|
|
114
|
+
return p->as.ary;
|
|
115
|
+
}
|
|
116
|
+
else {
|
|
117
|
+
return p->as.heap.ptr;
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
static inline void
|
|
122
|
+
RSTRUCT_SET(VALUE st, long k, VALUE v)
|
|
123
|
+
{
|
|
124
|
+
RB_OBJ_WRITE(st, &RSTRUCT_CONST_PTR(st)[k], v);
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
static inline VALUE
|
|
128
|
+
RSTRUCT_GET(VALUE st, long k)
|
|
129
|
+
{
|
|
130
|
+
return RSTRUCT_CONST_PTR(st)[k];
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
static inline VALUE
|
|
134
|
+
RSTRUCT_FIELDS_OBJ(VALUE st)
|
|
135
|
+
{
|
|
136
|
+
const long embed_len = RSTRUCT_EMBED_LEN(st);
|
|
137
|
+
VALUE fields_obj;
|
|
138
|
+
if (embed_len) {
|
|
139
|
+
RUBY_ASSERT(!FL_TEST_RAW(st, RSTRUCT_GEN_FIELDS));
|
|
140
|
+
fields_obj = RSTRUCT_GET(st, embed_len);
|
|
141
|
+
}
|
|
142
|
+
else {
|
|
143
|
+
fields_obj = RSTRUCT(st)->as.heap.fields_obj;
|
|
144
|
+
}
|
|
145
|
+
return fields_obj;
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
static inline void
|
|
149
|
+
RSTRUCT_SET_FIELDS_OBJ(VALUE st, VALUE fields_obj)
|
|
150
|
+
{
|
|
151
|
+
const long embed_len = RSTRUCT_EMBED_LEN(st);
|
|
152
|
+
if (embed_len) {
|
|
153
|
+
RUBY_ASSERT(!FL_TEST_RAW(st, RSTRUCT_GEN_FIELDS));
|
|
154
|
+
RSTRUCT_SET(st, embed_len, fields_obj);
|
|
155
|
+
}
|
|
156
|
+
else {
|
|
157
|
+
RB_OBJ_WRITE(st, &RSTRUCT(st)->as.heap.fields_obj, fields_obj);
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
#endif /* INTERNAL_STRUCT_H */
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
#ifndef INTERNAL_SYMBOL_H /*-*-C-*-vi:se ft=c:*/
|
|
2
|
+
#define INTERNAL_SYMBOL_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 Symbol.
|
|
10
|
+
*/
|
|
11
|
+
#include "ruby/ruby.h" /* for VALUE */
|
|
12
|
+
#include "ruby/encoding.h" /* for rb_encoding */
|
|
13
|
+
#include "internal/compilers.h" /* for __has_builtin */
|
|
14
|
+
|
|
15
|
+
#ifdef rb_sym_intern_ascii_cstr
|
|
16
|
+
# undef rb_sym_intern_ascii_cstr
|
|
17
|
+
#endif
|
|
18
|
+
|
|
19
|
+
/* symbol.c */
|
|
20
|
+
void rb_sym_global_symbols_mark_and_move(void);
|
|
21
|
+
VALUE rb_to_symbol_type(VALUE obj);
|
|
22
|
+
VALUE rb_sym_intern(const char *ptr, long len, rb_encoding *enc);
|
|
23
|
+
VALUE rb_sym_intern_ascii(const char *ptr, long len);
|
|
24
|
+
VALUE rb_sym_intern_ascii_cstr(const char *ptr);
|
|
25
|
+
int rb_is_const_name(VALUE name);
|
|
26
|
+
int rb_is_class_name(VALUE name);
|
|
27
|
+
int rb_is_instance_name(VALUE name);
|
|
28
|
+
int rb_is_local_name(VALUE name);
|
|
29
|
+
PUREFUNC(int rb_is_const_sym(VALUE sym));
|
|
30
|
+
PUREFUNC(int rb_is_attrset_sym(VALUE sym));
|
|
31
|
+
ID rb_make_internal_id(void);
|
|
32
|
+
ID rb_make_temporary_id(size_t n);
|
|
33
|
+
bool rb_obj_is_symbol_table(VALUE obj);
|
|
34
|
+
void rb_sym_global_symbol_table_foreach_weak_reference(int (*callback)(VALUE *key, void *data), void *data);
|
|
35
|
+
void rb_gc_free_dsymbol(VALUE);
|
|
36
|
+
int rb_static_id_valid_p(ID id);
|
|
37
|
+
void rb_free_global_symbol_table(void);
|
|
38
|
+
|
|
39
|
+
#if __has_builtin(__builtin_constant_p)
|
|
40
|
+
#define rb_sym_intern_ascii_cstr(ptr) \
|
|
41
|
+
(__builtin_constant_p(ptr) ? \
|
|
42
|
+
rb_sym_intern_ascii((ptr), (long)strlen(ptr)) : \
|
|
43
|
+
rb_sym_intern_ascii_cstr(ptr))
|
|
44
|
+
#endif
|
|
45
|
+
|
|
46
|
+
#endif /* INTERNAL_SYMBOL_H */
|
data/lib/datadog/ruby_core_source/{ruby-3.5.0-preview1 → ruby-4.0.0-preview2}/internal/thread.h
RENAMED
|
@@ -13,6 +13,7 @@
|
|
|
13
13
|
#include "ccan/list/list.h" /* for list in rb_io_close_wait_list */
|
|
14
14
|
|
|
15
15
|
struct rb_thread_struct; /* in vm_core.h */
|
|
16
|
+
struct rb_io;
|
|
16
17
|
|
|
17
18
|
#define RB_VM_SAVE_MACHINE_CONTEXT(th) \
|
|
18
19
|
do { \
|
|
@@ -55,26 +56,26 @@ VALUE rb_mutex_owned_p(VALUE self);
|
|
|
55
56
|
VALUE rb_exec_recursive_outer_mid(VALUE (*f)(VALUE g, VALUE h, int r), VALUE g, VALUE h, ID mid);
|
|
56
57
|
void ruby_mn_threads_params(void);
|
|
57
58
|
|
|
59
|
+
int rb_thread_io_wait(struct rb_io *io, int events, struct timeval * timeout);
|
|
58
60
|
int rb_thread_wait_for_single_fd(int fd, int events, struct timeval * timeout);
|
|
59
61
|
|
|
60
|
-
struct
|
|
61
|
-
|
|
62
|
-
VALUE closing_thread;
|
|
63
|
-
VALUE closing_fiber;
|
|
64
|
-
VALUE wakeup_mutex;
|
|
65
|
-
};
|
|
66
|
-
int rb_notify_fd_close(int fd, struct rb_io_close_wait_list *busy);
|
|
67
|
-
void rb_notify_fd_close_wait(struct rb_io_close_wait_list *busy);
|
|
62
|
+
size_t rb_thread_io_close_interrupt(struct rb_io *);
|
|
63
|
+
void rb_thread_io_close_wait(struct rb_io *);
|
|
68
64
|
|
|
69
65
|
void rb_ec_check_ints(struct rb_execution_context_struct *ec);
|
|
70
66
|
|
|
67
|
+
void rb_thread_free_native_thread(void *th_ptr);
|
|
68
|
+
|
|
71
69
|
RUBY_SYMBOL_EXPORT_BEGIN
|
|
72
70
|
|
|
73
71
|
void *rb_thread_prevent_fork(void *(*func)(void *), void *data); /* for ext/socket/raddrinfo.c */
|
|
74
72
|
|
|
75
73
|
/* Temporary. This API will be removed (renamed). */
|
|
76
|
-
VALUE rb_thread_io_blocking_region(rb_blocking_function_t *func, void *data1
|
|
77
|
-
VALUE rb_thread_io_blocking_call(rb_blocking_function_t *func, void *data1, int
|
|
74
|
+
VALUE rb_thread_io_blocking_region(struct rb_io *io, rb_blocking_function_t *func, void *data1);
|
|
75
|
+
VALUE rb_thread_io_blocking_call(struct rb_io *io, rb_blocking_function_t *func, void *data1, int events);
|
|
76
|
+
|
|
77
|
+
// Invoke the given function, with the specified argument, in a way that `IO#close` from another execution context can interrupt it.
|
|
78
|
+
VALUE rb_thread_io_blocking_operation(VALUE self, VALUE(*function)(VALUE), VALUE argument);
|
|
78
79
|
|
|
79
80
|
/* thread.c (export) */
|
|
80
81
|
int ruby_thread_has_gvl_p(void); /* for ext/fiddle/closure.c */
|
|
@@ -84,6 +85,8 @@ RUBY_SYMBOL_EXPORT_END
|
|
|
84
85
|
int rb_threadptr_execute_interrupts(struct rb_thread_struct *th, int blocking_timing);
|
|
85
86
|
bool rb_thread_mn_schedulable(VALUE thread);
|
|
86
87
|
|
|
88
|
+
bool rb_thread_resolve_unblock_function(rb_unblock_function_t **unblock_function, void **data2, struct rb_thread_struct *thread);
|
|
89
|
+
|
|
87
90
|
// interrupt exec
|
|
88
91
|
|
|
89
92
|
typedef VALUE (rb_interrupt_exec_func_t)(void *data);
|
|
@@ -91,6 +94,7 @@ typedef VALUE (rb_interrupt_exec_func_t)(void *data);
|
|
|
91
94
|
enum rb_interrupt_exec_flag {
|
|
92
95
|
rb_interrupt_exec_flag_none = 0x00,
|
|
93
96
|
rb_interrupt_exec_flag_value_data = 0x01,
|
|
97
|
+
rb_interrupt_exec_flag_new_thread = 0x02,
|
|
94
98
|
};
|
|
95
99
|
|
|
96
100
|
// interrupt the target_th and run func.
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
#ifndef INTERNAL_TRANSCODE_H /*-*-C-*-vi:se ft=c:*/
|
|
2
|
+
#define INTERNAL_TRANSCODE_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::Converter.
|
|
10
|
+
*/
|
|
11
|
+
#include "ruby/internal/config.h"
|
|
12
|
+
#include <stddef.h> /* for size_t */
|
|
13
|
+
#include "ruby/ruby.h" /* for VALUE */
|
|
14
|
+
#include "ruby/encoding.h" /* for rb_econv_t */
|
|
15
|
+
|
|
16
|
+
/* transcode.c */
|
|
17
|
+
extern VALUE rb_cEncodingConverter;
|
|
18
|
+
size_t rb_econv_memsize(rb_econv_t *);
|
|
19
|
+
|
|
20
|
+
/* vm.c */
|
|
21
|
+
void rb_free_transcoder_table(void);
|
|
22
|
+
|
|
23
|
+
#endif /* INTERNAL_TRANSCODE_H */
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
#ifndef INTERNAL_UTIL_H /*-*-C-*-vi:se ft=c:*/
|
|
2
|
+
#define INTERNAL_UTIL_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 corresponding util.c.
|
|
10
|
+
* @warning DO NOT ADD RANDOM GARBAGE HERE THIS FILE IS FOR util.c
|
|
11
|
+
*/
|
|
12
|
+
#include "ruby/internal/config.h"
|
|
13
|
+
#include <stddef.h> /* for size_t */
|
|
14
|
+
|
|
15
|
+
#ifdef HAVE_SYS_TYPES_H
|
|
16
|
+
# include <sys/types.h> /* for ssize_t (note: on Windows ssize_t is */
|
|
17
|
+
#endif /* `#define`d in ruby/config.h) */
|
|
18
|
+
|
|
19
|
+
/* util.c */
|
|
20
|
+
char *ruby_dtoa(double d_, int mode, int ndigits, int *decpt, int *sign, char **rve);
|
|
21
|
+
char *ruby_hdtoa(double d, const char *xdigs, int ndigits, int *decpt, int *sign, char **rve);
|
|
22
|
+
|
|
23
|
+
RUBY_SYMBOL_EXPORT_BEGIN
|
|
24
|
+
/* util.c (export) */
|
|
25
|
+
RUBY_SYMBOL_EXPORT_END
|
|
26
|
+
|
|
27
|
+
#endif /* INTERNAL_UTIL_H */
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
#ifndef INTERNAL_VARIABLE_H /*-*-C-*-vi:se ft=c:*/
|
|
2
|
+
#define INTERNAL_VARIABLE_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 variables.
|
|
10
|
+
*/
|
|
11
|
+
#include "ruby/internal/config.h"
|
|
12
|
+
#include <stddef.h> /* for size_t */
|
|
13
|
+
#include "constant.h" /* for rb_const_entry_t */
|
|
14
|
+
#include "ruby/internal/stdbool.h" /* for bool */
|
|
15
|
+
#include "ruby/ruby.h" /* for VALUE */
|
|
16
|
+
#include "shape.h" /* for shape_id_t */
|
|
17
|
+
|
|
18
|
+
/* variable.c */
|
|
19
|
+
void rb_gc_mark_global_tbl(void);
|
|
20
|
+
void rb_gc_update_global_tbl(void);
|
|
21
|
+
VALUE rb_search_class_path(VALUE);
|
|
22
|
+
VALUE rb_attr_delete(VALUE, ID);
|
|
23
|
+
void rb_autoload_str(VALUE mod, ID id, VALUE file);
|
|
24
|
+
VALUE rb_autoload_at_p(VALUE, ID, int);
|
|
25
|
+
void rb_autoload_copy_table_for_box(st_table *, const rb_box_t *);
|
|
26
|
+
NORETURN(VALUE rb_mod_const_missing(VALUE,VALUE));
|
|
27
|
+
rb_gvar_getter_t *rb_gvar_getter_function_of(ID);
|
|
28
|
+
rb_gvar_setter_t *rb_gvar_setter_function_of(ID);
|
|
29
|
+
void rb_gvar_readonly_setter(VALUE v, ID id, VALUE *_);
|
|
30
|
+
void rb_gvar_ractor_local(const char *name);
|
|
31
|
+
void rb_gvar_box_ready(const char *name);
|
|
32
|
+
|
|
33
|
+
/**
|
|
34
|
+
* Sets the name of a module.
|
|
35
|
+
*
|
|
36
|
+
* Non-permanently named classes can have a temporary name assigned (or
|
|
37
|
+
* cleared). In that case the name will be used for `#inspect` and `#to_s`, and
|
|
38
|
+
* nested classes/modules will be named with the temporary name as a prefix.
|
|
39
|
+
*
|
|
40
|
+
* After the module is assigned to a constant, the temporary name will be
|
|
41
|
+
* discarded, and the name will be computed based on the nesting.
|
|
42
|
+
*
|
|
43
|
+
* @param[in] mod An instance of ::rb_cModule.
|
|
44
|
+
* @param[in] name An instance of ::rb_cString.
|
|
45
|
+
* @retval mod
|
|
46
|
+
*/
|
|
47
|
+
VALUE rb_mod_set_temporary_name(VALUE, VALUE);
|
|
48
|
+
|
|
49
|
+
void rb_obj_copy_ivs_to_hash_table(VALUE obj, st_table *table);
|
|
50
|
+
void rb_obj_init_too_complex(VALUE obj, st_table *table);
|
|
51
|
+
void rb_evict_ivars_to_hash(VALUE obj);
|
|
52
|
+
VALUE rb_obj_field_get(VALUE obj, shape_id_t target_shape_id);
|
|
53
|
+
void rb_ivar_set_internal(VALUE obj, ID id, VALUE val);
|
|
54
|
+
attr_index_t rb_ivar_set_index(VALUE obj, ID id, VALUE val);
|
|
55
|
+
attr_index_t rb_obj_field_set(VALUE obj, shape_id_t target_shape_id, ID field_name, VALUE val);
|
|
56
|
+
VALUE rb_ivar_get_at(VALUE obj, attr_index_t index, ID id);
|
|
57
|
+
VALUE rb_ivar_get_at_no_ractor_check(VALUE obj, attr_index_t index);
|
|
58
|
+
|
|
59
|
+
RUBY_SYMBOL_EXPORT_BEGIN
|
|
60
|
+
/* variable.c (export) */
|
|
61
|
+
void rb_mark_generic_ivar(VALUE obj);
|
|
62
|
+
VALUE rb_const_missing(VALUE klass, VALUE name);
|
|
63
|
+
bool rb_class_ivar_set(VALUE klass, ID vid, VALUE value);
|
|
64
|
+
void rb_fields_tbl_copy(VALUE dst, VALUE src);
|
|
65
|
+
RUBY_SYMBOL_EXPORT_END
|
|
66
|
+
|
|
67
|
+
VALUE rb_ivar_lookup(VALUE obj, ID id, VALUE undef);
|
|
68
|
+
VALUE rb_gvar_get(ID);
|
|
69
|
+
VALUE rb_gvar_set(ID, VALUE);
|
|
70
|
+
VALUE rb_gvar_defined(ID);
|
|
71
|
+
void rb_const_warn_if_deprecated(const rb_const_entry_t *, VALUE, ID);
|
|
72
|
+
void rb_ensure_iv_list_size(VALUE obj, uint32_t current_len, uint32_t newsize);
|
|
73
|
+
|
|
74
|
+
#endif /* INTERNAL_VARIABLE_H */
|
|
@@ -56,7 +56,6 @@ void rb_vm_check_redefinition_by_prepend(VALUE klass);
|
|
|
56
56
|
int rb_vm_check_optimizable_mid(VALUE mid);
|
|
57
57
|
VALUE rb_yield_refine_block(VALUE refinement, VALUE refinements);
|
|
58
58
|
VALUE ruby_vm_special_exception_copy(VALUE);
|
|
59
|
-
PUREFUNC(st_table *rb_vm_fstring_table(void));
|
|
60
59
|
|
|
61
60
|
void rb_lastline_set_up(VALUE val, unsigned int up);
|
|
62
61
|
|
|
@@ -78,10 +77,11 @@ void rb_check_stack_overflow(void);
|
|
|
78
77
|
#define RB_BLOCK_NO_USE_PACKED_ARGS 2
|
|
79
78
|
VALUE rb_block_call2(VALUE obj, ID mid, int argc, const VALUE *argv, rb_block_call_func_t bl_proc, VALUE data2, long flags);
|
|
80
79
|
struct vm_ifunc *rb_current_ifunc(void);
|
|
80
|
+
VALUE rb_gccct_clear_table(VALUE);
|
|
81
81
|
|
|
82
|
-
#if USE_YJIT
|
|
82
|
+
#if USE_YJIT || USE_ZJIT
|
|
83
83
|
/* vm_exec.c */
|
|
84
|
-
extern uint64_t
|
|
84
|
+
extern uint64_t rb_vm_insn_count;
|
|
85
85
|
#endif
|
|
86
86
|
|
|
87
87
|
extern bool rb_free_at_exit;
|
|
@@ -121,7 +121,6 @@ int rb_get_node_id_from_frame_info(VALUE obj);
|
|
|
121
121
|
const struct rb_iseq_struct *rb_get_iseq_from_frame_info(VALUE obj);
|
|
122
122
|
|
|
123
123
|
VALUE rb_ec_backtrace_object(const struct rb_execution_context_struct *ec);
|
|
124
|
-
void rb_backtrace_use_iseq_first_lineno_for_last_location(VALUE self);
|
|
125
124
|
|
|
126
125
|
#define RUBY_DTRACE_CREATE_HOOK(name, arg) \
|
|
127
126
|
RUBY_DTRACE_HOOK(name##_CREATE, arg)
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
#ifndef INTERNAL_WARNINGS_H /*-*-C-*-vi:se ft=c:*/
|
|
2
|
+
#define INTERNAL_WARNINGS_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 to suppress / mandate warnings.
|
|
10
|
+
*/
|
|
11
|
+
#include "ruby/internal/warning_push.h"
|
|
12
|
+
#define COMPILER_WARNING_PUSH RBIMPL_WARNING_PUSH()
|
|
13
|
+
#define COMPILER_WARNING_POP RBIMPL_WARNING_POP()
|
|
14
|
+
#define COMPILER_WARNING_ERROR(flag) RBIMPL_WARNING_ERROR(flag)
|
|
15
|
+
#define COMPILER_WARNING_IGNORED(flag) RBIMPL_WARNING_IGNORED(flag)
|
|
16
|
+
#endif /* INTERNAL_WARNINGS_H */
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
#ifndef RUBY_INTERNAL_H /*-*-C-*-vi:se ft=c:*/
|
|
2
|
+
#define RUBY_INTERNAL_H 1
|
|
3
|
+
/**
|
|
4
|
+
* @author $Author$
|
|
5
|
+
* @date Tue May 17 11:42:20 JST 2011
|
|
6
|
+
* @copyright Copyright (C) 2011 Yukihiro Matsumoto
|
|
7
|
+
* @copyright This file is a part of the programming language Ruby.
|
|
8
|
+
* Permission is hereby granted, to either redistribute and/or
|
|
9
|
+
* modify this file, provided that the conditions mentioned in the
|
|
10
|
+
* file COPYING are met. Consult the file for details.
|
|
11
|
+
*/
|
|
12
|
+
#include "ruby/internal/config.h"
|
|
13
|
+
|
|
14
|
+
#ifdef __cplusplus
|
|
15
|
+
# error not for C++
|
|
16
|
+
#endif
|
|
17
|
+
|
|
18
|
+
#define LIKELY(x) RB_LIKELY(x)
|
|
19
|
+
#define UNLIKELY(x) RB_UNLIKELY(x)
|
|
20
|
+
|
|
21
|
+
#define numberof(array) ((int)(sizeof(array) / sizeof((array)[0])))
|
|
22
|
+
#define roomof(x, y) (((x) + (y) - 1) / (y))
|
|
23
|
+
#define type_roomof(x, y) roomof(sizeof(x), sizeof(y))
|
|
24
|
+
|
|
25
|
+
/* Prevent compiler from reordering access */
|
|
26
|
+
#define ACCESS_ONCE(type,x) (*((volatile type *)&(x)))
|
|
27
|
+
|
|
28
|
+
#define UNDEF_P RB_UNDEF_P
|
|
29
|
+
#define NIL_OR_UNDEF_P RB_NIL_OR_UNDEF_P
|
|
30
|
+
|
|
31
|
+
#include "ruby/ruby.h"
|
|
32
|
+
|
|
33
|
+
/* Following macros were formerly defined in this header but moved to somewhere
|
|
34
|
+
* else. In order to detect them we undef here. */
|
|
35
|
+
|
|
36
|
+
/* internal/array.h */
|
|
37
|
+
#undef RARRAY_AREF
|
|
38
|
+
|
|
39
|
+
/* internal/class.h */
|
|
40
|
+
#undef RClass
|
|
41
|
+
#undef RCLASS_SUPER
|
|
42
|
+
|
|
43
|
+
/* internal/hash.h */
|
|
44
|
+
#undef RHASH_IFNONE
|
|
45
|
+
#undef RHASH_SIZE
|
|
46
|
+
#undef RHASH_TBL
|
|
47
|
+
#undef RHASH_EMPTY_P
|
|
48
|
+
|
|
49
|
+
/* internal/struct.h */
|
|
50
|
+
#undef RSTRUCT_LEN
|
|
51
|
+
#undef RSTRUCT_PTR
|
|
52
|
+
#undef RSTRUCT_SET
|
|
53
|
+
#undef RSTRUCT_GET
|
|
54
|
+
|
|
55
|
+
/* Also, we keep the following macros here. They are expected to be
|
|
56
|
+
* overridden in each headers. */
|
|
57
|
+
|
|
58
|
+
/* internal/array.h */
|
|
59
|
+
#define rb_ary_new_from_args(...) rb_nonexistent_symbol(__VA_ARGS__)
|
|
60
|
+
|
|
61
|
+
/* internal/string.h */
|
|
62
|
+
#define rb_fstring_cstr(...) rb_nonexistent_symbol(__VA_ARGS__)
|
|
63
|
+
|
|
64
|
+
/* internal/symbol.h */
|
|
65
|
+
#define rb_sym_intern_ascii_cstr(...) rb_nonexistent_symbol(__VA_ARGS__)
|
|
66
|
+
|
|
67
|
+
/* internal/vm.h */
|
|
68
|
+
#define rb_funcallv(...) rb_nonexistent_symbol(__VA_ARGS__)
|
|
69
|
+
#define rb_method_basic_definition_p(...) rb_nonexistent_symbol(__VA_ARGS__)
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
/* MRI debug support */
|
|
73
|
+
|
|
74
|
+
/* gc.c */
|
|
75
|
+
void rb_obj_info_dump(VALUE obj);
|
|
76
|
+
void rb_obj_info_dump_loc(VALUE obj, const char *file, int line, const char *func);
|
|
77
|
+
|
|
78
|
+
/* debug.c */
|
|
79
|
+
|
|
80
|
+
RUBY_SYMBOL_EXPORT_BEGIN
|
|
81
|
+
void ruby_debug_breakpoint(void);
|
|
82
|
+
PRINTF_ARGS(void ruby_debug_printf(const char*, ...), 1, 2);
|
|
83
|
+
RUBY_SYMBOL_EXPORT_END
|
|
84
|
+
|
|
85
|
+
// show obj data structure without any side-effect
|
|
86
|
+
#define rp(obj) rb_obj_info_dump_loc((VALUE)(obj), __FILE__, __LINE__, RUBY_FUNCTION_NAME_STRING)
|
|
87
|
+
|
|
88
|
+
// same as rp, but add message header
|
|
89
|
+
#define rp_m(msg, obj) do { \
|
|
90
|
+
fputs((msg), stderr); \
|
|
91
|
+
rb_obj_info_dump((VALUE)(obj)); \
|
|
92
|
+
} while (0)
|
|
93
|
+
|
|
94
|
+
// `ruby_debug_breakpoint()` does nothing,
|
|
95
|
+
// but breakpoint is set in run.gdb, so `make gdb` can stop here.
|
|
96
|
+
#define bp() ruby_debug_breakpoint()
|
|
97
|
+
|
|
98
|
+
#define RBOOL(v) ((v) ? Qtrue : Qfalse)
|
|
99
|
+
#define RB_BIGNUM_TYPE_P(x) RB_TYPE_P((x), T_BIGNUM)
|
|
100
|
+
|
|
101
|
+
#ifndef __MINGW32__
|
|
102
|
+
#undef memcpy
|
|
103
|
+
#define memcpy ruby_nonempty_memcpy
|
|
104
|
+
#endif
|
|
105
|
+
#endif /* RUBY_INTERNAL_H */
|
|
@@ -175,7 +175,12 @@ ISEQ_COMPILE_DATA_CLEAR(rb_iseq_t *iseq)
|
|
|
175
175
|
static inline rb_iseq_t *
|
|
176
176
|
iseq_imemo_alloc(void)
|
|
177
177
|
{
|
|
178
|
-
|
|
178
|
+
rb_iseq_t *iseq = SHAREABLE_IMEMO_NEW(rb_iseq_t, imemo_iseq, 0);
|
|
179
|
+
|
|
180
|
+
// Clear out the whole iseq except for the flags.
|
|
181
|
+
memset((char *)iseq + sizeof(VALUE), 0, sizeof(rb_iseq_t) - sizeof(VALUE));
|
|
182
|
+
|
|
183
|
+
return iseq;
|
|
179
184
|
}
|
|
180
185
|
|
|
181
186
|
VALUE rb_iseq_ibf_dump(const rb_iseq_t *iseq, VALUE opt);
|
|
@@ -187,6 +192,7 @@ void rb_iseq_init_trace(rb_iseq_t *iseq);
|
|
|
187
192
|
int rb_iseq_add_local_tracepoint_recursively(const rb_iseq_t *iseq, rb_event_flag_t turnon_events, VALUE tpval, unsigned int target_line, bool target_bmethod);
|
|
188
193
|
int rb_iseq_remove_local_tracepoint_recursively(const rb_iseq_t *iseq, VALUE tpval);
|
|
189
194
|
const rb_iseq_t *rb_iseq_load_iseq(VALUE fname);
|
|
195
|
+
const rb_iseq_t *rb_iseq_compile_iseq(VALUE str, VALUE fname);
|
|
190
196
|
int rb_iseq_opt_frozen_string_literal(void);
|
|
191
197
|
|
|
192
198
|
#if VM_INSN_INFO_TABLE_IMPL == 2
|
|
@@ -73,10 +73,17 @@ typedef struct rb_callable_method_entry_struct { /* same fields with rb_method_e
|
|
|
73
73
|
#define METHOD_ENTRY_COMPLEMENTED(me) ((me)->flags & IMEMO_FL_USER3)
|
|
74
74
|
#define METHOD_ENTRY_COMPLEMENTED_SET(me) ((me)->flags |= IMEMO_FL_USER3)
|
|
75
75
|
#define METHOD_ENTRY_CACHED(me) ((me)->flags & IMEMO_FL_USER4)
|
|
76
|
-
#define METHOD_ENTRY_CACHED_SET(me) ((me)->flags |= IMEMO_FL_USER4)
|
|
77
76
|
#define METHOD_ENTRY_INVALIDATED(me) ((me)->flags & IMEMO_FL_USER5)
|
|
78
77
|
#define METHOD_ENTRY_INVALIDATED_SET(me) ((me)->flags |= IMEMO_FL_USER5)
|
|
79
78
|
|
|
79
|
+
static inline void
|
|
80
|
+
METHOD_ENTRY_CACHED_SET(rb_callable_method_entry_t *me)
|
|
81
|
+
{
|
|
82
|
+
if (!METHOD_ENTRY_CACHED(me)) {
|
|
83
|
+
me->flags |= IMEMO_FL_USER4;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
|
|
80
87
|
static inline void
|
|
81
88
|
METHOD_ENTRY_VISI_SET(rb_method_entry_t *me, rb_method_visibility_t visi)
|
|
82
89
|
{
|
|
@@ -197,6 +204,7 @@ struct rb_method_definition_struct {
|
|
|
197
204
|
|
|
198
205
|
ID original_id;
|
|
199
206
|
uintptr_t method_serial;
|
|
207
|
+
const rb_box_t *box;
|
|
200
208
|
};
|
|
201
209
|
|
|
202
210
|
struct rb_id_table;
|
|
@@ -247,12 +255,17 @@ const rb_callable_method_entry_t *rb_method_entry_complement_defined_class(const
|
|
|
247
255
|
void rb_method_entry_copy(rb_method_entry_t *dst, const rb_method_entry_t *src);
|
|
248
256
|
|
|
249
257
|
void rb_method_table_insert(VALUE klass, struct rb_id_table *table, ID method_id, const rb_method_entry_t *me);
|
|
258
|
+
void rb_method_table_insert0(VALUE klass, struct rb_id_table *table, ID method_id, const rb_method_entry_t *me, bool iclass_shared_mtbl);
|
|
250
259
|
|
|
251
260
|
void rb_scope_visibility_set(rb_method_visibility_t);
|
|
252
261
|
|
|
253
262
|
VALUE rb_unnamed_parameters(int arity);
|
|
254
263
|
|
|
264
|
+
void rb_vm_insert_cc_refinement(const struct rb_callcache *cc);
|
|
265
|
+
void rb_vm_delete_cc_refinement(const struct rb_callcache *cc);
|
|
266
|
+
|
|
255
267
|
void rb_clear_method_cache(VALUE klass_or_module, ID mid);
|
|
256
268
|
void rb_clear_all_refinement_method_cache(void);
|
|
269
|
+
void rb_invalidate_method_caches(struct rb_id_table *cm_tbl, VALUE cc_tbl);
|
|
257
270
|
|
|
258
271
|
#endif /* RUBY_METHOD_H */
|