FAQ
Hi!
As per the http://blog.golang.org/pipelines, Done channel is used to close the other goroutines once the main returns. But as per the design spec, we don't have to wait for goroutines to close before returning from main as they will be eventually closed when there are no references. And also http://stackoverflow.com/questions/25518531/ok-to-exit-program-with-active-goroutine , says we don't have to close the goroutines ourselves.
My doubt is, Should we always close the running goroutines before exiting main? Thanks! Regards,
Bharath MG,
http://www.bharathmg.com

--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Search Discussions

Discussion Posts

Follow ups

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 1 of 2 | next ›
Discussion Overview
groupgolang-nuts @
categoriesgo
postedJan 16, '15 at 3:05p
activeJan 16, '15 at 3:45p
posts2
users2
websitegolang.org

2 users in discussion

Bharath Mg: 1 post Ian Lance Taylor: 1 post

People

Translate

site design / logo © 2022 Grokbase