aboutsummaryrefslogtreecommitdiffstats
path: root/vm_method.c
diff options
context:
space:
mode:
author卜部昌平 <shyouhei@ruby-lang.org>2020-02-18 12:39:30 +0900
committer卜部昌平 <shyouhei@ruby-lang.org>2020-02-20 11:46:54 +0900
commit6788c375b15232e684dbd4b993b508413f2c74a9 (patch)
tree3cbff8ac502b39a9272a799e346d61faaf650c97 /vm_method.c
parent036a68ae2c6f3214cb5488da412444d773cbb65d (diff)
downloadruby-6788c375b15232e684dbd4b993b508413f2c74a9.tar.gz
suppress clang warnings
Starting clang 11, casts between pointer and (narrower-than-pointer) int are now warned. However all such thing in our repository are guaranteed safe. Let's suppress the warnings.
Diffstat (limited to 'vm_method.c')
-rw-r--r--vm_method.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/vm_method.c b/vm_method.c
index 900096629d..7b29b2c20c 100644
--- a/vm_method.c
+++ b/vm_method.c
@@ -288,7 +288,7 @@ rb_method_definition_set(const rb_method_entry_t *me, rb_method_definition_t *de
setup_method_cfunc_struct(UNALIGNED_MEMBER_PTR(def, body.cfunc), rb_f_notimplement, -1);
return;
case VM_METHOD_TYPE_OPTIMIZED:
- def->body.optimize_type = (enum method_optimized_type)opts;
+ def->body.optimize_type = (enum method_optimized_type)(intptr_t)opts;
return;
case VM_METHOD_TYPE_REFINED:
{