On Thu, 14 May 2009 01:27:15 -0400, Walter Bright
<[email protected]> wrote:
Robert Jacques wrote:
I don't see a place for "maybe shared" that isn't already handled by
simply "shared".
I gave a flip and incomplete answer there.
I'm not sure there is even a point to a function that could handle both
shared and unshared with the same code. First of all, sharing is going
to need some sort of synchronization; you're going to try and minimize
the amount of code that has to deal with shared. I can't see trying to
run an in-place sort on a shared array, for example. Can you imagine two
threads trying to sort the same array?
You're going to want to approach manipulating shared data differently
than unshared.
I agree for POD, but what classes where the synchronization is
encapsulated behind a virtual function call?
Also, does this mean 'scope' as a type is going away?