2017-01-18 16:10:15 -08:00
|
|
|
// lowlevel/ReOrdering.java
|
2021-01-31 15:42:31 -07:00
|
|
|
// (c)2021 MindView LLC: see Copyright.txt
|
2017-01-18 16:10:15 -08:00
|
|
|
// We make no guarantees that this code is fit for any purpose.
|
|
|
|
// Visit http://OnJava8.com for more book information.
|
|
|
|
|
|
|
|
public class ReOrdering implements Runnable {
|
|
|
|
int one, two, three, four, five, six;
|
|
|
|
volatile int volaTile;
|
2021-01-31 15:42:31 -07:00
|
|
|
@Override public void run() {
|
2017-01-18 16:10:15 -08:00
|
|
|
one = 1;
|
|
|
|
two = 2;
|
|
|
|
three = 3;
|
|
|
|
volaTile = 92;
|
|
|
|
int x = four;
|
|
|
|
int y = five;
|
|
|
|
int z = six;
|
|
|
|
}
|
|
|
|
}
|