From 2bb3ff2affbd6dcd14ac751bac333d7c3eeab611 Mon Sep 17 00:00:00 2001 From: Anna Shaleva Date: Wed, 24 Mar 2021 17:05:05 +0300 Subject: [PATCH] vm: return more detailed error from emit.Array --- pkg/vm/emit/emit.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/vm/emit/emit.go b/pkg/vm/emit/emit.go index 00f7c1b44..55949f8cb 100644 --- a/pkg/vm/emit/emit.go +++ b/pkg/vm/emit/emit.go @@ -94,7 +94,7 @@ func Array(w *io.BinWriter, es ...interface{}) { Bool(w, e) default: if es[i] != nil { - w.Err = errors.New("unsupported type") + w.Err = fmt.Errorf("unsupported type: %v", e) return } Opcodes(w, opcode.PUSHNULL)