From 48355ba9bfaa751d4197fc22f76af4d09814afe1 Mon Sep 17 00:00:00 2001 From: AnnaShaleva Date: Mon, 13 Dec 2021 15:28:08 +0300 Subject: [PATCH] vm: allow to emit int[32, 16, 8] and some of uints --- pkg/vm/emit/emit.go | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/pkg/vm/emit/emit.go b/pkg/vm/emit/emit.go index fcc246e4f..c3f3fb773 100644 --- a/pkg/vm/emit/emit.go +++ b/pkg/vm/emit/emit.go @@ -82,6 +82,20 @@ func Array(w *io.BinWriter, es ...interface{}) { Array(w, e...) case int64: Int(w, e) + case int32: + Int(w, int64(e)) + case uint32: + Int(w, int64(e)) + case int16: + Int(w, int64(e)) + case uint16: + Int(w, int64(e)) + case int8: + Int(w, int64(e)) + case uint8: + Int(w, int64(e)) + case int: + Int(w, int64(e)) case *big.Int: bigInt(w, e) case string: