From c939f473bdd7756830259976f0cc6a087fe56206 Mon Sep 17 00:00:00 2001 From: David Wood Date: Fri, 13 Dec 2024 02:35:32 +0800 Subject: [PATCH] fix: fix slice init length (#766) --- server/debugger/debugsession.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/debugger/debugsession.go b/server/debugger/debugsession.go index 3ffef3b6..4cf98999 100644 --- a/server/debugger/debugsession.go +++ b/server/debugger/debugsession.go @@ -649,7 +649,7 @@ func (s *session) convertStorageMapToDAPVariables( value *interpreter.StorageMap, ) []dap.Variable { - members := make([]dap.Variable, value.Count()) + members := make([]dap.Variable, 0, value.Count()) it := value.Iterator(inter) for {