Sharing in D

Jesse Phillips jessekphillips at gmail.com
Thu Jul 31 19:22:18 PDT 2008


On Wed, 30 Jul 2008 17:52:16 -0700, Walter Bright wrote:

> http://www.reddit.com/comments/6u7k0/sharing_in_d/

I haven't done much threading, so this sounds mostly good. On question I 
have relates to when a single threaded program/component is using 
libraries designed to support multithreading (thus it asks for a shared 
value). You aren't really doing any sharing you just wanted to call the 
function for what it does.

Would this never happen? Do I now have to cast my unshared to shared even 
though I'm not interested in sharing? My main point, is that if I'm 
writing a single threaded program, I shouldn't care about sharing even if 
the library I'm using does.



More information about the Digitalmars-d mailing list