Any particular reason for that? Neither is safer than the other and it's not clear to me that you can actually achieve the goal of having a compile-time check for the correctness of this type of conversion.
On Mon, 2019-09-23 at 02:36 -0700, fran...@adeven.com wrote: > But this relies on a string's representation being the same as, but a > bit smaller thabn, a []byte. I would prefer to use > the Slice/StringHeader. -- 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/cd1b5e5e5d6f8dd42c9f2f61196f122671017064.camel%40kortschak.io.