Skip to content

Commit 494ec85

Browse files
committed
go/types: update test case to exercise mutually recursive interfaces
Due to a typo, this test case was not actually exercising the bug described in #33656. Update it to do so. Interestingly, the comparison is now valid (as it should be) -- I suspect #33656 is actually fixed. Fixes #33656 Change-Id: If50a917f6477d8eb4f82f5a2a96bf5d9123ff0d4 Reviewed-on: https://go-review.googlesource.com/c/go/+/241263 Run-TryBot: Robert Findley <[email protected]> TryBot-Result: Gobot Gobot <[email protected]> Reviewed-by: Robert Griesemer <[email protected]>
1 parent 3a7f8cc commit 494ec85

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/go/types/testdata/cycles2.src

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ type A interface {
3737
}
3838

3939
type B interface {
40-
a() interface {
40+
b() interface {
4141
AB
4242
}
4343
}
@@ -59,8 +59,7 @@ var y interface {
5959
B
6060
}
6161

62-
// TODO(gri) This should be a valid compare. See #33656.
63-
var _ = x /* ERROR cannot compare */ == y
62+
var _ = x == y
6463

6564

6665
// Test case for issue 6638.

0 commit comments

Comments
 (0)