summaryrefslogtreecommitdiff
path: root/re.c
diff options
context:
space:
mode:
Diffstat (limited to 're.c')
-rw-r--r--re.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/re.c b/re.c
index cd1f997..487bcc1 100644
--- a/re.c
+++ b/re.c
@@ -2438,7 +2438,7 @@ rb_reg_initialize(VALUE obj, const char *s, long len, rb_encoding *enc,
options & ARG_REG_OPTION_MASK, err,
sourcefile, sourceline);
if (!re->ptr) return -1;
- OBJ_WRITE(obj, (VALUE *)&re->src, rb_enc_str_new(s, len, enc));
+ OBJ_WRITE(obj, &re->src, rb_enc_str_new(s, len, enc));
OBJ_FREEZE(re->src);
RB_GC_GUARD(unescaped);
return 0;
@@ -2473,7 +2473,7 @@ rb_reg_s_alloc(VALUE klass)
NEWOBJ_OF(re, struct RRegexp, klass, T_REGEXP | (RGENGC_WB_PROTECTED_REGEXP ? FL_WB_PROTECTED : 0));
re->ptr = 0;
- OBJ_WRITE(re, (VALUE *)&re->src, 0);
+ OBJ_WRITE(re, &re->src, 0);
re->usecnt = 0;
return (VALUE)re;