[RESOLVED] volatile fields
Im pretty sure I have a firm understanding of what making a class field volatile does. But Im just looking for some confirmation other than MS's fancy smancy explanation.
Basically when you add the keyword volatile to a field, it makes that variable "auto-locking" when it is accessed. So if you have two threads trying to access the same field, one thread will wait until the other thread has finished with accessing the field before it attempts to access the field, correct? volatile is essentially the same thing as locking the field for the duration of time that it is accessed, then unlocking it when the thread is done accessing it, am I right?