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

enum.c: write barrier

* enum.c (rb_nmin_run): set the class with write barrier.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57436 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2017-01-27 03:24:45 +00:00
parent 2c1bdb5849
commit 70410163f5

2
enum.c
View file

@ -1436,7 +1436,7 @@ rb_nmin_run(VALUE obj, VALUE num, int by, int rev, int ary)
if (rev) {
rb_ary_reverse(result);
}
*((VALUE *)&RBASIC(result)->klass) = rb_cArray;
RBASIC_SET_CLASS(result, rb_cArray);
return result;
}