title: Accessing different data members belonging to the same object from 2 different thread in C++
body: <p>I have a few objects I need to perform actions on from different threads in c++. I known it is necessary to lock any variable that may be used by more than one thread at the same time, but what if each thread is accessing (writing to) a different data member of the same object? For example, each thread is calling a different method of the object and none of the methods called modify the same data member. Is it safe as long as I don't access the same data member or do I need to lock the whole object anyway?</p>
  
  <p>I've looked around for explanations and details on this topic but every example seems to focus on single variables or non-member functions.</p>
  
  <p>To summarize:
  Can I safely access 2 different data members of the same object from 2 different thread without placing a lock on the whole object?</p>