diff --git a/src/runtime/baremetal.go b/src/runtime/baremetal.go index 9915f191b2..a8a74f6836 100644 --- a/src/runtime/baremetal.go +++ b/src/runtime/baremetal.go @@ -37,20 +37,20 @@ func growHeap() bool { return false } -//export malloc +//export tinygo_malloc func libc_malloc(size uintptr) unsafe.Pointer { // Note: this zeroes the returned buffer which is not necessary. // The same goes for bytealg.MakeNoZero. return alloc(size, nil) } -//export calloc +//export tinygo_calloc func libc_calloc(nmemb, size uintptr) unsafe.Pointer { // No difference between calloc and malloc. return libc_malloc(nmemb * size) } -//export free +//export tinygo_free func libc_free(ptr unsafe.Pointer) { free(ptr) }