commit | 85ca682349af2cb1aa6b1eecac794aeb73d24f15 | [log] [tgz] |
---|---|---|
author | Than McIntosh <thanm@google.com> | Mon Feb 05 11:57:18 2018 -0500 |
committer | Ian Lance Taylor <iant@golang.org> | Thu May 03 17:18:47 2018 +0000 |
tree | 406253fdd42c7cc4de4c2ed6b074da7b6ee40cad | |
parent | e367bffce3d2c49b456fdf41ab097bded2bcbc3b [diff] |
compiler: avoid crashing on invalid non-integer array length Tweak the array type checking code to avoid crashing on array types whose length expressions are explicit non-integer types (for example, "float64(10)"). If such constructs are seen, issue an "invalid array bound" error. Fixes golang/go#13486. Change-Id: Iaf8ed8fda23d8624fa4f15e1a6c4f5b53225d190 Reviewed-on: https://go-review.googlesource.com/91975 Reviewed-by: Ian Lance Taylor <iant@golang.org>