From: SASADA Koichi Date: 2017-03-27T14:40:43+09:00 Subject: [ruby-core:80368] Re: [Ruby trunk Feature#13295] [PATCH] compile.c: apply opt_str_freeze to String#-@ (uminus) On 2017/03/26 15:16, Eric Wong wrote: > Oops, I already committed r57828 before this message. > opt_str_freeze insn already takes care of redefinition in > insns.def; so extra check for compile.c won't be affected. now it checks only 'freeze' redefinition (*1). I'll fix it before 2.5 release (maybe with new a instruction (*2), which replace existing opt_str_freeze). *1: class String def -@ p :redef self end end p -'foo' *2: opt_str_freeze "foo" -> opt_frozen "foo", label # jump if String#freeze or String#-@ # are not redefined putstring "foo" send "-@" label: (or something smarter insn) -- // SASADA Koichi at atdot dot net Unsubscribe: