Hi How can I find the list of fields of all structs with some particular comment using *ast*(*or maybe other tool available in the lang*)?
Using *ast.Inspect(),* we get different callbacks for diff ast nodes, like:- - *ast.Comment :- gives comment - *ast.TypeSpec: gives the name of the struct - *ast.StructType: gives the list of fields of a struct But my problem is -- - When type is **ast.Comment*, I have comments, but I don't have access to struct name and its fields - When type is **ast.TypeSpec*, I have struct name but I don't haves access to it's comments. - When type is **ast.StructType*, I have access to its fields, but I don't have access to comment & struct name. My question is how can I merge all these three callbacks to ensure this is the same comments and fields belonging to the same struct? -- 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/1f1c6790-fd9e-4eec-b8a0-dd322c8827c3o%40googlegroups.com.