It is common practice to have multiple entries in an alist with the same key. E.g. CLtL2 explicitly touts this as a feature:
Moreover, because the searching function assoc searches the a-list in order, new entries can ``shadow'' old entries
The order of keys should thus be maintained in alist=, otherwise this function might e.g. return non-nil for '(("foo" . 1) ("foo" . 2)) and '(("foo" . 2) ("foo" . 1)).
It is common practice to have multiple entries in an alist with the same key. E.g. CLtL2 explicitly touts this as a feature:
The order of keys should thus be maintained in
alist=
, otherwise this function might e.g. return non-nil for'(("foo" . 1) ("foo" . 2))
and'(("foo" . 2) ("foo" . 1))
.