Merge pull request #5792 from dearblue/stderr

Retrieve the `StandardError` class from `mrb_state`
This commit is contained in:
Yukihiro "Matz" Matsumoto
2022-09-17 22:48:50 +09:00
committed by GitHub
+1 -1
View File
@@ -309,7 +309,7 @@ mrb_mruby_errno_gem_init(mrb_state *mrb)
{
struct RClass *e, *eno, *sce, *ste;
ste = mrb_class_get_id(mrb, MRB_SYM(StandardError));
ste = mrb->eStandardError_class;
sce = mrb_define_class(mrb, "SystemCallError", ste);
mrb_define_class_method(mrb, sce, "_sys_fail", mrb_sce_sys_fail, MRB_ARGS_REQ(1));