value_t new_heap_pair(runtime_t *runtime, value_t e0, value_t e1) { TRY_DEF(result, new_heap_array(runtime, 2)); set_array_at(result, 0, e0); set_array_at(result, 1, e1); TRY(ensure_frozen(runtime, result)); return result; }
value_t plankton_set_operation_contents(value_t object, runtime_t *runtime, value_t contents) { BEGIN_UNPACK_PLANKTON(contents); UNPACK_PLANKTON_FIELD(snInDomain(vdInteger), type); UNPACK_PLANKTON_FIELD(snNoCheck, value); set_operation_type(object, get_integer_value(type_value)); set_operation_value(object, value_value); return ensure_frozen(runtime, object); }
value_t new_heap_triple(runtime_t *runtime, value_t e0, value_t e1, value_t e2) { TRY_DEF(result, new_heap_array(runtime, 3)); set_array_at(result, 0, e0); set_array_at(result, 1, e1); set_array_at(result, 2, e2); TRY(ensure_frozen(runtime, result)); return result; }
value_t ensure_call_tags_owned_values_frozen(runtime_t *runtime, value_t self) { TRY(ensure_frozen(runtime, get_call_tags_entries(self))); return success(); }
value_t ensure_signature_owned_values_frozen(runtime_t *runtime, value_t self) { return ensure_frozen(runtime, get_signature_tags(self)); }
value_t ensure_methodspace_owned_values_frozen(runtime_t *runtime, value_t self) { TRY(ensure_id_hash_map_frozen(runtime, get_methodspace_inheritance(self), mfFreezeValues)); TRY(ensure_frozen(runtime, get_methodspace_methods(self))); return success(); }
value_t ensure_signature_map_owned_values_frozen(runtime_t *runtime, value_t self) { TRY(ensure_frozen(runtime, get_signature_map_entries(self))); return success(); }
// Post-processes an allocation result appropriately based on the given set of // allocation flags. static value_t post_process_result(runtime_t *runtime, value_t result, alloc_flags_t flags) { if (flags == afFreeze) TRY(ensure_frozen(runtime, result)); return success(); }