Skip to content

Instantly share code, notes, and snippets.

@jordanorelli
Created December 9, 2011 05:08
Show Gist options
  • Save jordanorelli/1450272 to your computer and use it in GitHub Desktop.
Save jordanorelli/1450272 to your computer and use it in GitHub Desktop.
make Go puke
package main
import (
"fmt"
"time"
"runtime"
)
func tick() {
for {
fmt.Println("tick.", runtime.Goroutines())
time.Sleep(1e9)
go tick()
}
}
func main() {
c := make(chan bool)
go tick()
<-c
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment