mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
error.h: add extern "C" for C++
This commit is contained in:
@@ -7,6 +7,10 @@
|
||||
#ifndef MRUBY_ERROR_H
|
||||
#define MRUBY_ERROR_H
|
||||
|
||||
#if defined(__cplusplus)
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
void mrb_sys_fail(mrb_state *mrb, const char *mesg);
|
||||
mrb_value mrb_exc_new_str(mrb_state *mrb, struct RClass* c, mrb_value str);
|
||||
#define mrb_exc_new_str_lit(mrb, c, lit) mrb_exc_new_str(mrb, c, mrb_str_new_lit(mrb, (lit)))
|
||||
@@ -17,4 +21,8 @@ void mrb_print_backtrace(mrb_state *mrb);
|
||||
mrb_value mrb_exc_backtrace(mrb_state *mrb, mrb_value exc);
|
||||
mrb_value mrb_get_backtrace(mrb_state *mrb);
|
||||
|
||||
#if defined(__cplusplus)
|
||||
} /* extern "C" { */
|
||||
#endif
|
||||
|
||||
#endif /* MRUBY_ERROR_H */
|
||||
|
||||
Reference in New Issue
Block a user