proposal: go/ast: add FieldList.Variables() iter.Seq2[*Ident, *Field] #73395
Labels
LibraryProposal
Issues describing a requested change to the Go standard library or x/ libraries, but not to a tool
Proposal
Milestone
Background: it is common when working with the
go/ast
package to need to enumerate the list of parameter or result variables declared by a function.Proposal: We propose to add a Variables method to ast.FieldList that returns an iterator over the sequence of variables, as defined below.
For implementation, see astutil.FlatFields in x/tools.
The text was updated successfully, but these errors were encountered: