Closed pfps closed 1 week ago
As I've said elsewhere, we use INFRA (to the degree possible) for describing our values. INFRA is used in many W3C specs typically for representing that values associated with JSON strings. It would be unusual for our value space to use everything from INFRA except (ordered) map
. Practically speaking, when parsing a JSON Object, implementations will construct the map in sequence, and there are cases where preserving this order is useful. But, the JSON model is that map entries are unordered, which really only becomes significant when comparing two maps, which we provide for. Maps are accessed by key, so ordinal location of a map entry within a map is not important.
My opinion remains that we should continue to use the INFRA map definition.
OK, but then you are responsible for ensuring that all the messiness of using an ordered map is handled. I have provided an alternative that requires fewer complications.
The value space still contains orderd maps (with insignicant order). It would be much better to start out with a map datatype that is unordered instead of going through all the contortions to try to eliminate all vestiges of the order.
https://en.wikipedia.org/wiki/Associative_array appears to be a reasonable reference for an unordered finite map.