From e16a738940ef55f87f34810b7ec4608d22362512 Mon Sep 17 00:00:00 2001 From: Nathan Froyd Date: Wed, 16 Aug 2023 16:33:16 -0400 Subject: [PATCH] update `memsize` with new types --- bin/memsize | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/bin/memsize b/bin/memsize index 568534bc4f5..f1f5097dd95 100755 --- a/bin/memsize +++ b/bin/memsize @@ -10,14 +10,16 @@ results = node["name"], node.fetch("child_nodes", []).sum do |child_node| case child_node["type"] - when "integer" + when "uint32", "constant" 4 when "node", "node?" 8 when "location", "location?" 16 - when "node[]", "string", "token", "token?", "location[]" + when "node[]", "string", "token", "token?", "location[]", "constant[]" 24 + when "flags" + 0 else raise "Unknown type: #{child_node["type"]}" end