Programming with Futures, Lattices, and Quiescence — Philipp Haller
Reordering not always a problem!
• Example 3:
8
import scala.collection.concurrent.TrieMap
val set = new TrieMap[Int, Int]
Future {
set.put(1, 0)
}
set.put(2, 0)
Eventually, set contains
both 1 and 2, always
Bottom line: it depends on the datatype