On 3/14/15 11:24 AM, Russel Winder via Digitalmars-d wrote:
But yes, it certainly shows you can create shared-memory "multi-threading" this way,
So your affirmation has been refuted.
but anyone actually doing it would be being very silly.
That's "design by prayer". Aren't most bugs created by people doing very silly things?
Sending addresses down multiple channels
One is enough.
is obvious here and definitely not the right thing to do unless the datum contains an embedded lock which is then used. cf. https://talks.golang.org/2012/10things.slide#3
Yes, of course it's not the right thing to do. Your point being...?
It would be better if channels could only accept value types, and not reference types.
Probably not as that would further hamstrung the language. Andrei