--
A holding the lock for the length of A’ communicates that A’ is inside the critical section and must be careful to preserve invariants. A’ internally locking a reentrant lock is ambiguous with respect to invariant expectations. The practical implications are as important as the theoretical. There’s inherent complexity in both - non reentrant locks tends to surface complexity and make the behaviors/assumptions more obvious. Very, very occasionally reentrant locks are worth the ambiguity they introduce, but primarily in callback heavy code (which Go doesn’t encourage as much as other languages/APIs).
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+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/A14270D5-880D-4639-B6D8-6237F9C6ABF2%40siliconsprawl.com. |
- [go-nuts] There is a passage in book <The Go Programming ... GuanYun
- [go-nuts] Re: There is a passage in book <The Go Pro... peterGo
- Re: [go-nuts] Re: There is a passage in book <Th... Robert Engels
- Re: [go-nuts] There is a passage in book <Th... Eli Lindsey
- [go-nuts] There is a passage in book <The Go Program... Robert Engels
- Re: [go-nuts] There is a passage in book <The Go Pro... Eli Lindsey
- Re: [go-nuts] There is a passage in book <The Go... Robert Engels
- Fwd: Re: [go-nuts] There is a passage in book <The G... Jan Mercl