From e86c9cb57c0ee799ca66d18612e15c6c8983f872 Mon Sep 17 00:00:00 2001 From: "Yukihiro \"Matz\" Matsumoto" Date: Mon, 30 Aug 2021 07:35:58 +0900 Subject: Do no use return values from `mrb_ensure_` functions. They return the checking argument without modification, so the values are already there. Maybe we should change the return type to `void` but keep them unchanged for compatibility. --- src/class.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/class.c') diff --git a/src/class.c b/src/class.c index 855a7715c..b683deda0 100644 --- a/src/class.c +++ b/src/class.c @@ -2379,7 +2379,7 @@ mrb_mod_const_get(mrb_state *mrb, mrb_value mod) } /* const get with class path string */ - path = mrb_ensure_string_type(mrb, path); + mrb_ensure_string_type(mrb, path); ptr = RSTRING_PTR(path); len = RSTRING_LEN(path); off = 0; -- cgit v1.2.3