]> Cypherpunks.ru repositories - gostls13.git/blob - test/fixedbugs/bug406.go
6df3c5cae669ce107d7fa3d147efc3d31f37c1e9
[gostls13.git] / test / fixedbugs / bug406.go
1 // run
2
3 // Copyright 2012 The Go Authors.  All rights reserved.
4 // Use of this source code is governed by a BSD-style
5 // license that can be found in the LICENSE file.
6
7 // Issue 2821
8 package main
9
10 type matrix struct {
11         e []int
12 }
13
14 func (a matrix) equal() bool {
15         for _ = range a.e {
16         }
17         for range a.e {
18         }
19         return true
20 }
21
22 func main() {
23         var a matrix
24         var i interface{}
25         i = true && a.equal()
26         _ = i
27 }