mirror of https://github.com/golang/go.git
go/types: add test verifying corner-case behavior of iota
For #22341. Change-Id: I7e586c58075e4c835ef97701db2f38bdf7558521 Reviewed-on: https://go-review.googlesource.com/71974 Run-TryBot: Robert Griesemer <gri@golang.org> Reviewed-by: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org>
This commit is contained in:
parent
85177f4276
commit
b0680b474c
|
|
@ -118,6 +118,8 @@ func TestValuesInfo(t *testing.T) {
|
|||
{`package f7a; var _ complex128 = -1e-2000i`, `-1e-2000i`, `complex128`, `(0 + 0i)`},
|
||||
{`package f6b; var _ = 1e-2000i`, `1e-2000i`, `complex128`, `(0 + 0i)`},
|
||||
{`package f7b; var _ = -1e-2000i`, `-1e-2000i`, `complex128`, `(0 + 0i)`},
|
||||
|
||||
{`package g0; const (a = len([iota]int{}); b; c); const _ = c`, `c`, `int`, `2`}, // issue #22341
|
||||
}
|
||||
|
||||
for _, test := range tests {
|
||||
|
|
|
|||
Loading…
Reference in New Issue