-
Matthew Dempsky authored
Apply static bounds checking logic during type checking even to zero-element arrays, but skip synthesized OINDEX nodes that the compiler has asserted are within bounds (such as the ones generated while desugaring ORANGE nodes). This matches the logic in walkexpr that also skips static bounds checking when Bounded is true. Passes toolstash/buildall. Fixes #12944. Change-Id: I14ba03d71c002bf969d69783bec8d1a8e10e7d75 Reviewed-on: https://go-review.googlesource.com/15902Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
67722fea