On Thursday, September 6, 2018 at 6:34:54 PM UTC-5, Eric Raymond wrote:
> In the attached program, I would like to be able to remove the &x argument > from ListFields. That is, I want the Inner code to be able to reflect on > the Outer instance without having to be fed the address of the Outer > instance explicitly. I specifically do *not* want to move the method to > Outer - reflection from within Inner is the point of the exercise. > I actually have a solution for the &x problem. The handler-struct can be an interface with some form of SetFakeSuperClass() method which the Kommandant constructor calls. The only problem is that it is be brittle if the Kmdt struct is copied. But realistically I'm having a hard time coming up with a scenario where that is relevant and Kommandant is the breakage rather than the code using it. -- 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. For more options, visit https://groups.google.com/d/optout.