I don't think the docs imply that. For one, a[0] is nil, and b[0] isn't.

On Thu, Sep 17, 2020 at 5:58 PM tapi...@gmail.com <tapir....@gmail.com>
wrote:

>
> package main
>
> import (
>   "fmt"
>   "reflect"
> )
>
> func main() {
>   f()
> }
>
> func f() {
>   type S []S
>   var a, b S
>   a = S{0: b}
>   b = S{0: a}
>   fmt.Println(reflect.DeepEqual(a, b))
> }
>
> Now it prints false. But it looks the docs indicates it should print true.
>
> --
> You received this message because you are subscribed to the Google Groups
> "golang-nuts" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to golang-nuts+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/golang-nuts/dbe73874-ec0f-413d-bed6-47f213bede91n%40googlegroups.com
> <https://groups.google.com/d/msgid/golang-nuts/dbe73874-ec0f-413d-bed6-47f213bede91n%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/CAEkBMfGRN4NWj1kzX4nPR_6%2BT4bz_fADr6NR6skktPg9vDv_KA%40mail.gmail.com.

Reply via email to