diff options
-rw-r--r-- | test/interface1.go | 2 | ||||
-rw-r--r-- | test/interface10.go | 2 | ||||
-rw-r--r-- | test/interface2.go | 2 | ||||
-rw-r--r-- | test/interface3.go | 2 | ||||
-rw-r--r-- | test/interface5.go | 2 | ||||
-rw-r--r-- | test/interface6.go | 2 | ||||
-rw-r--r-- | test/interface7.go | 3 | ||||
-rw-r--r-- | test/interface8.go | 3 | ||||
-rw-r--r-- | test/interface9.go | 2 |
9 files changed, 20 insertions, 0 deletions
diff --git a/test/interface1.go b/test/interface1.go index 649a955f6..202c37d86 100644 --- a/test/interface1.go +++ b/test/interface1.go @@ -4,6 +4,8 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +// Check that interface{M()} = *interface{M()} produces a compiler error. + package main type Inst interface { diff --git a/test/interface10.go b/test/interface10.go index c52a20fcd..d216b890d 100644 --- a/test/interface10.go +++ b/test/interface10.go @@ -4,6 +4,8 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +// Check methods derived from embedded interface and *interface values. + package main import "os" diff --git a/test/interface2.go b/test/interface2.go index 53676787f..1e3758069 100644 --- a/test/interface2.go +++ b/test/interface2.go @@ -4,6 +4,8 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +// Check that interface conversion fails when method is missing. + package main type S struct diff --git a/test/interface3.go b/test/interface3.go index 04af91a02..93298bce7 100644 --- a/test/interface3.go +++ b/test/interface3.go @@ -4,6 +4,8 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +// Check methods with different return types. + package main type S struct { a int } diff --git a/test/interface5.go b/test/interface5.go index 86036a778..3b5ed01ca 100644 --- a/test/interface5.go +++ b/test/interface5.go @@ -4,6 +4,8 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +// Static error messages about interface conversions. + package main type T struct { a int } diff --git a/test/interface6.go b/test/interface6.go index c675595fd..49926f0a2 100644 --- a/test/interface6.go +++ b/test/interface6.go @@ -4,6 +4,8 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +// Interface values containing structures. + package main import "os" diff --git a/test/interface7.go b/test/interface7.go index ee1ac3116..a52d7a5a1 100644 --- a/test/interface7.go +++ b/test/interface7.go @@ -4,6 +4,9 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +// Interface comparisons using types hidden +// inside reflected-on structs. + package main import "reflect" diff --git a/test/interface8.go b/test/interface8.go index f7dc04d34..4c2d4d4c5 100644 --- a/test/interface8.go +++ b/test/interface8.go @@ -4,6 +4,9 @@ // $G $F.go && $L $F.$A && ./$A.out +// Implicit methods for embedded types. +// Mixed pointer and non-pointer receivers. + package main type T int diff --git a/test/interface9.go b/test/interface9.go index 9ba5864a8..42214bd76 100644 --- a/test/interface9.go +++ b/test/interface9.go @@ -4,6 +4,8 @@ // errchk $G $F.go +// Error messages about missing implicit methods. + package main type T int |