Hello ! I'm trying to write a tool that will: - parse my code, and find variable assignment - check if the assigned variable is a parameter in the current function (or a function parameter in the current scope)
func myFunc(a *A){ a.foo = "bar" } In the code above, I want to detect that "a" in "a.foo" is referencing the "a *A" parameter in my function. I already know how to use ast.Walk(), and find the *ast.Ident for "a" in "a.foo". I also know that I can use types.Info.Defs with conf.Check(). Can someone give me some advice please ? -- 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.