diff options
| author | Daniel Martà <mvdan@mvdan.cc> | 2018-03-14 10:50:49 +0000 |
|---|---|---|
| committer | Matthew Dempsky <mdempsky@google.com> | 2018-03-22 18:38:19 +0000 |
| commit | 02798ed936cc3c4789ee8a3ca5ac26a24105947d (patch) | |
| tree | 70059716e9eff0ff64cdbc42a0059876ae0ac5af /src/cmd/vendor/github.com/google | |
| parent | 48f990b4a5743426ebf39b9cf2930fe100ebca9e (diff) | |
| download | go-02798ed936cc3c4789ee8a3ca5ac26a24105947d.tar.xz | |
cmd/compile: use more range fors in gc
Slightly simplifies the code. Made sure to exclude the cases that would
change behavior, such as when the iterated value is a string, when the
index is modified within the body, or when the slice is modified.
Also checked that all the elements are of pointer type, to avoid the
corner case where non-pointer types could be copied by mistake.
Change-Id: Iea64feb2a9a6a4c94ada9ff3ace40ee173505849
Reviewed-on: https://go-review.googlesource.com/100557
Run-TryBot: Daniel Martà <mvdan@mvdan.cc>
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
Diffstat (limited to 'src/cmd/vendor/github.com/google')
0 files changed, 0 insertions, 0 deletions
