FAQ
Hi all,

Can someone explain to me why compiling this code:
http://play.golang.org/p/cy_LZz2G0M

gets the error:
prog.go:22: cannot take the address of (*g).(Y)

Is there some valid Go syntax to achieve what I'm trying to do?

Thanks,

Jon

--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Search Discussions

  • Dan Kortschak at Sep 9, 2014 at 6:21 am

    On Mon, 2014-09-08 at 23:16 -0700, Jon Bodner wrote:
    Can someone explain to me why compiling this code:
    http://play.golang.org/p/cy_LZz2G0M

    gets the error:
    prog.go:22: cannot take the address of (*g).(Y)

    Is there some valid Go syntax to achieve what I'm trying to do?
    http://play.golang.org/p/keyvLnL1cI

    The result of the assertion is not addressable until it has been
    assigned.


    --
    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+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/d/optout.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupgolang-nuts @
categoriesgo
postedSep 9, '14 at 6:16a
activeSep 9, '14 at 6:21a
posts2
users2
websitegolang.org

2 users in discussion

Jon Bodner: 1 post Dan Kortschak: 1 post

People

Translate

site design / logo © 2021 Grokbase