diff options
| author | Yukihiro "Matz" Matsumoto <[email protected]> | 2020-08-11 15:06:51 +0900 |
|---|---|---|
| committer | Yukihiro "Matz" Matsumoto <[email protected]> | 2020-08-11 15:06:51 +0900 |
| commit | 5e55b61c44f512b31094f20aee08f6f921344870 (patch) | |
| tree | 1b7012b0336261163b44db5a996341e18591d80e /mrbgems/mruby-compiler | |
| parent | 4695dfdcb6ce412d4aa4efb146c56c5c32a50e43 (diff) | |
| download | mruby-5e55b61c44f512b31094f20aee08f6f921344870.tar.gz mruby-5e55b61c44f512b31094f20aee08f6f921344870.zip | |
Fix `mrb_int` and `size_t` combination warnings.
Diffstat (limited to 'mrbgems/mruby-compiler')
| -rw-r--r-- | mrbgems/mruby-compiler/core/parse.y | 4 | ||||
| -rw-r--r-- | mrbgems/mruby-compiler/core/y.tab.c | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/mrbgems/mruby-compiler/core/parse.y b/mrbgems/mruby-compiler/core/parse.y index 23fad6e8a..3ae2022cf 100644 --- a/mrbgems/mruby-compiler/core/parse.y +++ b/mrbgems/mruby-compiler/core/parse.y @@ -6380,7 +6380,7 @@ MRB_API void mrb_parser_set_filename(struct mrb_parser_state *p, const char *f) { mrb_sym sym; - size_t i; + uint16_t i; mrb_sym* new_table; sym = mrb_intern_cstr(p->mrb, f); @@ -6389,7 +6389,7 @@ mrb_parser_set_filename(struct mrb_parser_state *p, const char *f) for (i = 0; i < p->filename_table_length; ++i) { if (p->filename_table[i] == sym) { - p->current_filename_index = (int)i; + p->current_filename_index = i; return; } } diff --git a/mrbgems/mruby-compiler/core/y.tab.c b/mrbgems/mruby-compiler/core/y.tab.c index a22846e75..d9a7b72de 100644 --- a/mrbgems/mruby-compiler/core/y.tab.c +++ b/mrbgems/mruby-compiler/core/y.tab.c @@ -12177,7 +12177,7 @@ MRB_API void mrb_parser_set_filename(struct mrb_parser_state *p, const char *f) { mrb_sym sym; - size_t i; + uint16_t i; mrb_sym* new_table; sym = mrb_intern_cstr(p->mrb, f); @@ -12186,7 +12186,7 @@ mrb_parser_set_filename(struct mrb_parser_state *p, const char *f) for (i = 0; i < p->filename_table_length; ++i) { if (p->filename_table[i] == sym) { - p->current_filename_index = (int)i; + p->current_filename_index = i; return; } } |
