Skip to content

Commit

Permalink
Fix argc of rb_define_singleton_method for dt_inherited (#612)
Browse files Browse the repository at this point in the history
argc of rb_define_singleton_method means the number of parameters
excluding klass itself. On the other hand dt_inherited expects
only klass as arguments. Then 0 is appropriate in this case.
  • Loading branch information
yui-knk authored and deivid-rodriguez committed Dec 22, 2019
1 parent ac61f39 commit 198302f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ext/byebug/context.c
Expand Up @@ -682,5 +682,5 @@ Init_byebug_context(VALUE mByebug)
rb_define_method(cContext, "tracing=", Context_set_tracing, 1);

cDebugThread = rb_define_class_under(mByebug, "DebugThread", rb_cThread);
rb_define_singleton_method(cDebugThread, "inherited", dt_inherited, 1);
rb_define_singleton_method(cDebugThread, "inherited", dt_inherited, 0);
}

0 comments on commit 198302f

Please sign in to comment.