blob: 053afb1c6025d986f024ad03cb7ff10573f0da73 [file] [log] [blame]
Peter Collingbournead9841e2014-11-27 00:06:42 +00001// RUN: llgo -o %t %s
2// RUN: %t 2>&1 | FileCheck %s
3
4// CHECK: A
5// CHECK-NEXT: B
6
7package main
8
9type BI interface {
10 B()
11}
12
13type AI interface {
14 A()
15 BI
16}
17
18type S struct{}
19
20func (s S) A() {
21 println("A")
22}
23
24func (s S) B() {
25 println("B")
26}
27
28func main() {
29 var ai AI = S{}
30 ai.A()
31 ai.B()
32}