mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
hash.c (mrb_hash_compact): call hash_modify instead of mrb_check_frozen
Currently, hash_modify() only calls mrb_check_frozen, but we may add new checks in the future; ref #6485
This commit is contained in:
+1
-1
@@ -1828,7 +1828,7 @@ mrb_hash_compact(mrb_state *mrb, mrb_value hash)
|
||||
uint32_t size = ht_p ? ht_size(h) : ar_size(h);
|
||||
uint32_t dec = 0;
|
||||
|
||||
mrb_check_frozen(mrb, h);
|
||||
hash_modify(mrb, hash);
|
||||
H_EACH(h, entry) {
|
||||
if (mrb_nil_p(entry->val)) {
|
||||
entry_delete(entry);
|
||||
|
||||
Reference in New Issue
Block a user