Merge branch 'exception' of https://github.com/dearblue/mruby into dearblue-exception

This commit is contained in:
Yukihiro "Matz" Matsumoto
2022-05-01 20:00:37 +09:00
4 changed files with 57 additions and 51 deletions
+2 -2
View File
@@ -17,11 +17,11 @@ MRB_BEGIN_DECL
struct RException {
MRB_OBJECT_HEADER;
struct iv_tbl *iv;
struct RString *mesg;
struct RObject *mesg; // NULL or probably RString
struct RObject *backtrace; // NULL, RArray or RData
};
#define mrb_exc_ptr(v) ((struct RException*)mrb_ptr(v))
#define MRB_EXC_MESG_STRING_FLAG 0x100
MRB_API mrb_noreturn void mrb_sys_fail(mrb_state *mrb, const char *mesg);
MRB_API mrb_value mrb_exc_new_str(mrb_state *mrb, struct RClass* c, mrb_value str);