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

rb_method_name_error: delete unused code

If you look at the code flow (break -> goto), this assignment never
makes any sense.  Should just remove.

I _guess_ this behaviour is unintended.  Original code at commit
4dc1a21809 did something.  It might be
the code flow that is buggy.  However rubyspec already includes this
particular edge case at ruby/core/module/undef_method_spec.rb.  I don't
think we can change the way it is any longer.
This commit is contained in:
卜部昌平 2020-06-17 09:58:35 +09:00
parent ccb7a4b9f2
commit af6e63a9df

1
proc.c
View file

@ -1817,7 +1817,6 @@ rb_method_name_error(VALUE klass, VALUE str)
case T_MODULE:
case T_CLASS:
c = obj;
s = MSG("");
break;
default:
break;