API review of VarHandles
Paul Sandoz
paul.sandoz at oracle.com
Wed Feb 10 09:52:27 UTC 2016
> On 10 Feb 2016, at 02:03, Hans Boehm <hboehm at google.com> wrote:
>
> I found this a bit scary for naive readers:
>
> * The Java Language Specification permits operations to be executed in
> * orders different than are apparent in program source code, subject to
> * constraints arising, for example, from the use of locks, {@code volatile}
> * fields or VarHandles.
>
> I would change it to
>
> * The Java Language Specification permits other threads to observe operations
> * as if they were executed in orders different than are apparent in program source code,
> * subject to constraints arising, for example, from the use of locks, {@code volatile}
> * fields or VarHandles.
>
> to make it clear that we are not talking about intra-thread semantics here.
>
> That way it will hopefully only be scary to experts, as intended.
>
Many thanks! updated to what you suggest,
Paul.
More information about the valhalla-dev
mailing list