summaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
authordearblue <[email protected]>2021-12-17 23:02:04 +0900
committerdearblue <[email protected]>2021-12-17 23:02:04 +0900
commit6b8582c95d64b75837e6778c712d705e07edad17 (patch)
tree8db635b5dd92ebc46218ebcb383239b4f96ec838 /include
parent9b65d0dc861f4a5d1605fa7fccb56f1758a2bd6f (diff)
downloadmruby-6b8582c95d64b75837e6778c712d705e07edad17.tar.gz
mruby-6b8582c95d64b75837e6778c712d705e07edad17.zip
Add `bin/mrbc --no-ext-ops` switch
Print an error if `OP_EXT[123]` is needed when generating mruby binary. This may be useful for mruby/c. Inspired by #5590.
Diffstat (limited to 'include')
-rw-r--r--include/mruby/compile.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/mruby/compile.h b/include/mruby/compile.h
index aa1739ef1..5c52a13a7 100644
--- a/include/mruby/compile.h
+++ b/include/mruby/compile.h
@@ -31,6 +31,7 @@ typedef struct mrbc_context {
mrb_bool no_exec:1;
mrb_bool keep_lv:1;
mrb_bool no_optimize:1;
+ mrb_bool no_ext_ops:1;
const struct RProc *upper;
size_t parser_nerr;
@@ -155,6 +156,7 @@ struct mrb_parser_state {
mrb_bool no_optimize:1;
mrb_bool capture_errors:1;
+ mrb_bool no_ext_ops:1;
const struct RProc *upper;
struct mrb_parser_message error_buffer[10];
struct mrb_parser_message warn_buffer[10];