From 085d50b4303c7cc4d51845a1815a7dfdca43bcf6 Mon Sep 17 00:00:00 2001 From: Roman Khimov Date: Mon, 18 May 2020 18:57:22 +0300 Subject: [PATCH] interop/util: extend documentation --- pkg/interop/util/util.go | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/pkg/interop/util/util.go b/pkg/interop/util/util.go index 1f05d4941..1aba144cb 100644 --- a/pkg/interop/util/util.go +++ b/pkg/interop/util/util.go @@ -1,12 +1,19 @@ +/* +Package util contains some special useful functions that are provided by compiler and VM. +*/ package util -// FromAddress is an utility function that converts an NEO address to its hash. +// FromAddress is an utility function that converts a Neo address to its hash +// (160 bit BE value in a 20 byte slice). It can only be used for strings known +// at compilation time, because the convertion is actually being done by the +// compiler. func FromAddress(address string) []byte { return nil } -// Equals compares a with b and will return true whether a and b -// are equal. +// Equals compares a with b and will return true when a and b are equal. It's +// implemented as an EQUAL VM opcode, so the rules of comparison are those +// of EQUAL. func Equals(a, b interface{}) bool { return false }