OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [go.go-torture/] [execute/] [go-3.go] - Blame information for rev 821

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 698 jeremybenn
package main
2
 
3
type I interface { send(chan <- int) }
4
 
5
type S struct { v int }
6
func (p *S) send(c chan <- int) { c <- p.v }
7
 
8
func main() {
9
  s := S{0};
10
  var i I = &s;
11
  c := make(chan int);
12
  go i.send(c);
13
  if <- c != 0 { panic(0) }
14
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.