logoalt Hacker News

pwaglandtoday at 8:59 AM0 repliesview on HN

That is exact problem.

Basically JEP401 guarantees that just adding "value" to the class won't change behaviour, which also means that you are not allowed to see object tearing, which requires atomic operations on the field.

Relaxing that would break safe publication rules, at least for Java.