Parse stack params (#119)
* small fixes * gofmt * bytearray parsing * tests * removed unnecessary files * added more types for bytearray * iter * made TryParseArray parameter variadic * fixes after review * fix after review * misprints * updated array reverse * imports/fmt * naming
This commit is contained in:
parent
7c1147f04f
commit
a058598ecc
5 changed files with 210 additions and 4 deletions
|
@ -6,9 +6,9 @@ import (
|
|||
)
|
||||
|
||||
func TestArrayReverse(t *testing.T) {
|
||||
arr := []byte{0x01, 0x02, 0x03, 0x04}
|
||||
arr := []byte{0x01, 0x02, 0x03, 0x04, 0x05}
|
||||
have := ArrayReverse(arr)
|
||||
want := []byte{0x04, 0x03, 0x02, 0x01}
|
||||
want := []byte{0x05, 0x04, 0x03, 0x02, 0x01}
|
||||
if bytes.Compare(have, want) != 0 {
|
||||
t.Fatalf("expected %v got %v", want, have)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue