From 28f5e12c24edda376c863090c09406185373167b Mon Sep 17 00:00:00 2001 From: naruse Date: Sun, 8 May 2016 17:44:51 +0000 Subject: * configure.in: check function attirbute const and pure, and define CONSTFUNC and PUREFUNC if available. Note that I don't add those options as default because it still shows many false-positive (it seems not to consider longjmp). * vm_eval.c (stack_check): get rb_thread_t* as an argument to avoid duplicate call of GET_THREAD(). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54952 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- gc.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'gc.c') diff --git a/gc.c b/gc.c index 6923ccdfee..92885754a4 100644 --- a/gc.c +++ b/gc.c @@ -2033,6 +2033,7 @@ rb_objspace_data_type_name(VALUE obj) } } +PUREFUNC(static inline int is_pointer_to_heap(rb_objspace_t *objspace, void *ptr);) static inline int is_pointer_to_heap(rb_objspace_t *objspace, void *ptr) { @@ -2900,6 +2901,7 @@ rb_objspace_call_finalizer(rb_objspace_t *objspace) ATOMIC_SET(finalizing, 0); } +PUREFUNC(static inline int is_id_value(rb_objspace_t *objspace, VALUE ptr)); static inline int is_id_value(rb_objspace_t *objspace, VALUE ptr) { -- cgit v1.2.3