aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/slice.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/runtime/slice.go')
-rw-r--r--src/runtime/slice.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/runtime/slice.go b/src/runtime/slice.go
index 5cda11d9b0..b316cdd7b3 100644
--- a/src/runtime/slice.go
+++ b/src/runtime/slice.go
@@ -154,6 +154,6 @@ func slicestringcopy(to []byte, fm string) int {
racewriterangepc(unsafe.Pointer(&to[0]), uintptr(n), callerpc, pc)
}
- memmove(unsafe.Pointer(&to[0]), unsafe.Pointer((*stringStruct)(unsafe.Pointer(&fm)).str), uintptr(n))
+ memmove(unsafe.Pointer(&to[0]), unsafe.Pointer(stringStructOf(&fm).str), uintptr(n))
return n
}