Original post

I’m trying to get a method from a type embedded in a type a few calls down in methods. I’ve got the code here (cleaned up so you only need to look at what’s needed for the problem) https://play.golang.org/p/p1nhHxJe2e2 .

The line I am trying to get to work is m := vField.MethodByName("Validate") to get access to the method func (tz *TZConfig) Validate(...) .

This is just part of some initialization so using reflect and perhaps being a little slower than written other ways is not an issue.

A clue as to what I am missing to make this work would be much appreciated.