From 8b841166a86b2ee6babe41d4eaaa9eab9a309b21 Mon Sep 17 00:00:00 2001 From: Simone Mosciatti Date: Tue, 8 Mar 2022 13:29:45 +0100 Subject: [PATCH] add small comment --- ua/encode.go | 1 + 1 file changed, 1 insertion(+) diff --git a/ua/encode.go b/ua/encode.go index a8975e56..891282c4 100644 --- a/ua/encode.go +++ b/ua/encode.go @@ -149,6 +149,7 @@ func writeArray(val reflect.Value, name string) ([]byte, error) { buf.WriteUint32(uint32(val.Len())) // loop over elements + // we write all the elements, also the zero values for i := 0; i < val.Len(); i++ { ename := fmt.Sprintf("%s[%d]", name, i) b, err := encode(val.Index(i), ename)