diff options
| author | Yukihiro "Matz" Matsumoto <[email protected]> | 2018-11-15 20:15:10 +0900 |
|---|---|---|
| committer | Yukihiro "Matz" Matsumoto <[email protected]> | 2018-11-15 21:01:56 +0900 |
| commit | 61f49690e43cea3df6ebbdf424cf6777826056b0 (patch) | |
| tree | 25d4f8e4ecec412c79ac4232fae00bfe93663cda /src/state.c | |
| parent | 1bea1e2050ee4c1b3e558a307c7d2731f6b52823 (diff) | |
| download | mruby-61f49690e43cea3df6ebbdf424cf6777826056b0.tar.gz mruby-61f49690e43cea3df6ebbdf424cf6777826056b0.zip | |
Remove `filename`&`lines` from `mrb_irep` struct.
This patch slightly reduce memory consumption (2% for my test).
Diffstat (limited to 'src/state.c')
| -rw-r--r-- | src/state.c | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/src/state.c b/src/state.c index 18d104555..5583a77e5 100644 --- a/src/state.c +++ b/src/state.c @@ -168,10 +168,6 @@ mrb_irep_free(mrb_state *mrb, mrb_irep *irep) } mrb_free(mrb, irep->reps); mrb_free(mrb, irep->lv); - if (irep->own_filename) { - mrb_free(mrb, (void *)irep->filename); - } - mrb_free(mrb, irep->lines); mrb_debug_info_free(mrb, irep->debug_info); mrb_free(mrb, irep); } @@ -273,7 +269,6 @@ mrb_add_irep(mrb_state *mrb) irep = (mrb_irep *)mrb_malloc(mrb, sizeof(mrb_irep)); *irep = mrb_irep_zero; irep->refcnt = 1; - irep->own_filename = FALSE; return irep; } |
