Project

General

Profile

« Previous | Next » 

Revision b4efa4b7

Added by peterzhu2118 (Peter Zhu) almost 2 years ago

Don't copy RUBY_FL_PROMOTED flag in rb_obj_setup

RUBY_FL_PROMOTED is used by the garbage collector to track when an
object becomes promoted to the old generation. rb_obj_setup must not
copy that flag over because then it may become out-of-sync with the age
of the object.

This fixes a bug in Method#clone where the cloned Method object may get
RUBY_FL_PROMOTED incorrectly set.