mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
Safeguard against trying to use C++ exception handling in C code
This commit is contained in:
committed by
Yukihiro "Matz" Matsumoto
parent
401ad4586f
commit
00e6121260
@@ -7,6 +7,10 @@
|
||||
#ifndef MRB_THROW_H
|
||||
#define MRB_THROW_H
|
||||
|
||||
#if defined(MRB_ENABLE_CXX_EXCEPTION) && !defined(__cplusplus)
|
||||
#error Trying to use C++ exception handling in C code
|
||||
#endif
|
||||
|
||||
#if defined(MRB_ENABLE_CXX_EXCEPTION) && defined(__cplusplus)
|
||||
|
||||
#define MRB_TRY(buf) do { try {
|
||||
|
||||
Reference in New Issue
Block a user