• Matthew Dempsky's avatar
    cmd/compile: refactor generic AST walking code · 12c9d753
    Matthew Dempsky authored
    racewalk's "foreach" function applies a function to all of a Node's
    immediate children, but with a non-idiomatic signature.
    
    This CL reworks it to recursively iterate over the entire subtree
    rooted at Node and provides a way to short-circuit iteration.
    
    Passes toolstash -cmp for std cmd with -race.
    
    Change-Id: I738b73953d608709802c97945b7e0f4e4940d3f4
    Reviewed-on: https://go-review.googlesource.com/71911
    Run-TryBot: Matthew Dempsky <mdempsky@google.com>
    TryBot-Result: Gobot Gobot <gobot@golang.org>
    Reviewed-by: 's avatarRobert Griesemer <gri@golang.org>
    12c9d753
Name
Last commit
Last update
.github Loading commit data...
api Loading commit data...
doc Loading commit data...
lib/time Loading commit data...
misc Loading commit data...
src Loading commit data...
test Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
AUTHORS Loading commit data...
CONTRIBUTING.md Loading commit data...
CONTRIBUTORS Loading commit data...
LICENSE Loading commit data...
PATENTS Loading commit data...
README.md Loading commit data...
favicon.ico Loading commit data...
robots.txt Loading commit data...