diff --git a/docs/slice.md b/docs/slice.md index 650af1c..1a7db9c 100644 --- a/docs/slice.md +++ b/docs/slice.md @@ -1106,7 +1106,7 @@ import ( func main() { str1 := "a" str2 := "b" - res := slice.ToSlice(str1, str2) + res := slice.ToSlicePointer(str1, str2) fmt.Println(res) // res -> []*string{&str1, &str2} } ``` diff --git a/docs/slice_zh-CN.md b/docs/slice_zh-CN.md index 98dcbe6..fe9c77a 100644 --- a/docs/slice_zh-CN.md +++ b/docs/slice_zh-CN.md @@ -1107,7 +1107,7 @@ import ( func main() { str1 := "a" str2 := "b" - res := slice.ToSlice(str1, str2) + res := slice.ToSlicePointer(str1, str2) fmt.Println(res) // res -> []*string{&str1, &str2} } ```