From 56065f0686e6798fff2ee7319f0f03026f427c13 Mon Sep 17 00:00:00 2001 From: S-H-GAMELINKS Date: Thu, 2 Sep 2021 12:15:21 +0900 Subject: Using SYMBOL_P macro --- struct.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'struct.c') diff --git a/struct.c b/struct.c index 9207c6291d..e1c0145c16 100644 --- a/struct.c +++ b/struct.c @@ -1060,7 +1060,7 @@ rb_struct_pos(VALUE s, VALUE *name) long i; VALUE idx = *name; - if (RB_TYPE_P(idx, T_SYMBOL)) { + if (SYMBOL_P(idx)) { return struct_member_pos(s, idx); } else if (RB_TYPE_P(idx, T_STRING)) { -- cgit v1.2.1