diff options
author | Noah Gibbs <noah.gibbs@shopify.com> | 2022-06-06 18:47:24 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-06 13:47:24 -0400 |
commit | 653e517eefaa0c4f2710b30b4dff9a9dad7b9d6a (patch) | |
tree | aed944b278b9ac89637538f66fad2d0fcf57e30b /yjit/bindgen | |
parent | c5475f42694eff35465c3332e0182c0611ca5918 (diff) | |
download | ruby-653e517eefaa0c4f2710b30b4dff9a9dad7b9d6a.tar.gz |
Use bindgen to import Ruby constants wherever possible. (#5943)
Constants that can't be imported via bindgen should have
a comment saying why not.
Diffstat (limited to 'yjit/bindgen')
-rw-r--r-- | yjit/bindgen/src/main.rs | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/yjit/bindgen/src/main.rs b/yjit/bindgen/src/main.rs index 26717d018c..6ccdbc0cc5 100644 --- a/yjit/bindgen/src/main.rs +++ b/yjit/bindgen/src/main.rs @@ -125,6 +125,21 @@ fn main() { .allowlist_var("rb_cArray") .allowlist_var("rb_cHash") + // From include/ruby/internal/fl_type.h + .allowlist_type("ruby_fl_type") + .allowlist_type("ruby_fl_ushift") + + // From include/ruby/internal/core/robject.h + .allowlist_type("ruby_robject_flags") + .allowlist_type("ruby_robject_consts") + + // From include/ruby/internal/core/rarray.h + .allowlist_type("ruby_rarray_flags") + .allowlist_type("ruby_rarray_consts") + + // From include/ruby/internal/core/rclass.h + .allowlist_type("ruby_rmodule_flags") + // From ruby/internal/globals.h .allowlist_var("rb_mKernel") @@ -214,6 +229,10 @@ fn main() { .blocklist_type("rb_control_frame_struct") .opaque_type("rb_control_frame_struct") .allowlist_function("rb_vm_bh_to_procval") + .allowlist_type("vm_special_object_type") + .allowlist_var("VM_ENV_DATA_INDEX_SPECVAL") + .allowlist_var("VM_ENV_DATA_INDEX_FLAGS") + .allowlist_var("VM_ENV_DATA_SIZE") // From yjit.c .allowlist_function("rb_iseq_(get|set)_yjit_payload") |