interp: implement runtime.sliceCopy

This implements the copy() built-in function. It may not work in all
cases, but should work in most cases.

This commit gets the following 3 packages to compile, according to
tinygo-site/imports/main.go:

  * encoding/base32
  * encoding/base64
  * encoding/pem (was blocked by encoding/base64)
This commit is contained in:
Ayke van Laethem
2019-09-22 00:16:26 +02:00
committed by Ayke
parent 4ea1559d46
commit 582457b81e
8 changed files with 201 additions and 7 deletions
+1
View File
@@ -12,6 +12,7 @@ import (
func TestInterp(t *testing.T) {
for _, name := range []string{
"basic",
"slice-copy",
} {
name := name // make tc local to this closure
t.Run(name, func(t *testing.T) {