From df631b4de94295aa72fe4e839bf2d8b8ddec1073 Mon Sep 17 00:00:00 2001 From: georgeee Date: Tue, 28 Nov 2023 19:12:49 +0100 Subject: [PATCH] Remove a TODO in location_of_account_batch Justification: we don't have a choice in this function because unlike loading an account by location here we can't tell of an account whether it's a new one or just wasn't loaded from parent. It might have an implication to performance of transaction processing (I do see some db lookups despite the fact that we preload a lot of stuff). But I think we'll handle it via special-casing unsafe_preload function, not right here. --- src/lib/merkle_mask/masking_merkle_tree.ml | 1 - 1 file changed, 1 deletion(-) diff --git a/src/lib/merkle_mask/masking_merkle_tree.ml b/src/lib/merkle_mask/masking_merkle_tree.ml index 3236313c3b7..caae338cd05 100644 --- a/src/lib/merkle_mask/masking_merkle_tree.ml +++ b/src/lib/merkle_mask/masking_merkle_tree.ml @@ -668,7 +668,6 @@ module Make (Inputs : Inputs_intf.S) = struct Base.location_of_account (get_parent t) account_id let location_of_account_batch t = - (* TODO consider handling special case of empty addresses *) self_find_or_batch_lookup (fun id -> (id, Option.map ~f:Option.some @@ self_find_location t id)) Base.location_of_account_batch t