On 5/5/16 5:54 AM, Stephen Colebourne wrote:
To be clear, I believe that the spec of Set.of() and Map.of() should
require iteration order matching insertion order (because the order is
very clearly defined in this case and anything else will be
surprising).

OK. This would be a spec change. The specification of the Set static factory methods contains the clause

The iteration order of set elements is unspecified and is subject to change.

There is the corresponding clause for the Map static factory methods. [1]

You can certainly propose or discuss spec changes, but if you do, I'd like it to be decoupled from this code review thread.

Thanks,

s'marks


[1] http://hg.openjdk.java.net/jdk9/jdk9/jdk/rev/e6c3d2856593

Reply via email to