Thanks, that is a great explanation :) On Thu, Jun 18, 2020, 03:49 Axel Wagner <axel.wagner...@googlemail.com> wrote:
> I'd also say that converting between []Foo and []Stringer isn't actually > definable in a type-safe manner: > https://blog.merovius.de/2018/06/03/why-doesnt-go-have-variance-in.html > Slices are writable as well as readable, so if you could convert []Foo to > []Stringer you'd also have to say what happens when you assign a > *different* Stringer to an element of it - and the only thing that could > happen is a panic. > > The memory-layout explanation never rang true to me. After all, we *do* > allow converting between string and []rune, which has the same problem. > > On Thu, Jun 18, 2020, 04:53 Miguel Angel Rivera Notararigo < > ntr...@gmail.com> wrote: > >> Oh, it was a FAQ haha sorry about that and thanks Tyler and Ian :D >> >> -- >> 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/CAF9DLC%3DuAUJ3R8%3Dt%3DakiAiG-JPaxvkju7T%3DeU9saEirbOy8Z%3DA%40mail.gmail.com >> <https://groups.google.com/d/msgid/golang-nuts/CAF9DLC%3DuAUJ3R8%3Dt%3DakiAiG-JPaxvkju7T%3DeU9saEirbOy8Z%3DA%40mail.gmail.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/CAF9DLCm7yJng_oFgsyYYt3GpTMgsXN4TPJgnHnb7x-nE618qJw%40mail.gmail.com.