how does 'shared' affect member variables?

bitwise via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Sat May 9 11:41:58 PDT 2015


What does 'shared' do to member variables?

It makes sense to me to put it on a global variable, but what sense does  
it make putting it on a member of a class? What happens if you try to  
access a member of a class/struct instance from another thread that is not  
marked 'shared'?

Also, I wasn't able to find any thorough documentation on shared, so if  
someone has a link, that would be helpful.

  Thanks
    Bit


More information about the Digitalmars-d-learn mailing list