Originally posted by me:
- Thread1 resumes to execute check() //result: false
- Thread2 resumes to execute setY(i) and then check() //result: true
Read that as:
- Thread1 resumes to execute check() //result: TRUE
- Thread2 resumes to execute setY(i) and then check() //result: FALSE