1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* marshal.c (r_object0): suppressed a warning.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25307 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2009-10-12 02:28:48 +00:00
parent 4aa531ead4
commit bd2a1db5af

View file

@ -1507,9 +1507,9 @@ r_object0(struct load_arg *arg, int *ivp, VALUE extmod)
if (!ivp || !has_encoding(arg)) { if (!ivp || !has_encoding(arg)) {
VALUE pat; VALUE pat;
VALUE dst; VALUE dst;
char *rsrc = static const char rsrc[] =
"(?<!\\\\)((?:\\\\\\\\)*)\\\\([ghijklmopquyEFHIJKLNOPQRSTUVXY])"; "(?<!\\\\)((?:\\\\\\\\)*)\\\\([ghijklmopquyEFHIJKLNOPQRSTUVXY])";
pat = rb_reg_new(rsrc, strlen(rsrc), 0); pat = rb_reg_new(rsrc, sizeof(rsrc)-1, 0);
dst = rb_usascii_str_new_cstr("\\1\\2"); dst = rb_usascii_str_new_cstr("\\1\\2");
rb_funcall(str, rb_intern("gsub!"), 2, pat, dst); rb_funcall(str, rb_intern("gsub!"), 2, pat, dst);
} }