summaryrefslogtreecommitdiff
path: root/method.h
diff options
context:
space:
mode:
authorTakashi Kokubun <[email protected]>2024-03-01 15:01:20 -0800
committerTakashi Kokubun <[email protected]>2024-03-01 15:02:28 -0800
commit61fbd29e14c0bd06ca4c063ff34332b272874a13 (patch)
tree2e42f1d8a09525cdfdea06d71ce9de818557a957 /method.h
parent5a3ae06a09d183bf1b7752ddd9f5e800a033f7ae (diff)
Skip a redundant check for the rb_obj_hash case
Also, refactor the cfunc struct to use a new rb_cfunc_t.
Diffstat (limited to 'method.h')
-rw-r--r--method.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/method.h b/method.h
index ad66690c6a..fdc7c263d1 100644
--- a/method.h
+++ b/method.h
@@ -136,8 +136,9 @@ typedef struct rb_method_iseq_struct {
rb_cref_t * cref; /*!< class reference, should be marked */
} rb_method_iseq_t; /* check rb_add_method_iseq() when modify the fields */
+typedef VALUE (*rb_cfunc_t)(ANYARGS);
typedef struct rb_method_cfunc_struct {
- VALUE (*func)(ANYARGS);
+ rb_cfunc_t func;
VALUE (*invoker)(VALUE recv, int argc, const VALUE *argv, VALUE (*func)(ANYARGS));
int argc;
} rb_method_cfunc_t;