mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
obsolete mrb_object; opposite of bc870ce
This commit is contained in:
+3
-3
@@ -5157,13 +5157,13 @@ load_exec(mrb_state *mrb, parser_state *p, mrbc_context *c)
|
||||
|
||||
n = snprintf(buf, sizeof(buf), "line %d: %s\n",
|
||||
p->error_buffer[0].lineno, p->error_buffer[0].message);
|
||||
mrb->exc = (struct RObject*)mrb_object(mrb_exc_new(mrb, E_SYNTAX_ERROR, buf, n));
|
||||
mrb->exc = mrb_obj_ptr(mrb_exc_new(mrb, E_SYNTAX_ERROR, buf, n));
|
||||
mrb_parser_free(p);
|
||||
return mrb_undef_value();
|
||||
}
|
||||
else {
|
||||
static const char msg[] = "syntax error";
|
||||
mrb->exc = (struct RObject*)mrb_object(mrb_exc_new(mrb, E_SYNTAX_ERROR, msg, sizeof(msg) - 1));
|
||||
mrb->exc = mrb_obj_ptr(mrb_exc_new(mrb, E_SYNTAX_ERROR, msg, sizeof(msg) - 1));
|
||||
mrb_parser_free(p);
|
||||
return mrb_undef_value();
|
||||
}
|
||||
@@ -5172,7 +5172,7 @@ load_exec(mrb_state *mrb, parser_state *p, mrbc_context *c)
|
||||
mrb_parser_free(p);
|
||||
if (n < 0) {
|
||||
static const char msg[] = "codegen error";
|
||||
mrb->exc = (struct RObject*)mrb_object(mrb_exc_new(mrb, E_SCRIPT_ERROR, msg, sizeof(msg) - 1));
|
||||
mrb->exc = mrb_obj_ptr(mrb_exc_new(mrb, E_SCRIPT_ERROR, msg, sizeof(msg) - 1));
|
||||
return mrb_nil_value();
|
||||
}
|
||||
if (c) {
|
||||
|
||||
Reference in New Issue
Block a user