Previous chapter: #9: Punt Slot Descriptors (Change)

Dylan Design Notes: #10: Element-Setter Signals Error (Clarification)

Dylan Design Notes

#10: Element-Setter Signals Error (Clarification)

Version 1, March 1993

It is an error if element-setter cannot successfully set the element of a sequence. This design note requires an error to be signaled in that case, preventing programs from silently returning an incorrect result or otherwise failing.


Specify that if element-setter cannot successfully set the element of a sequence, it should signal an error. The second paragraph of the description of element-setter on page 127 of the Dylan manual should be changed to read, "An error is signaled if a program calls elementsetter with a key that is not already a key to collection, unless the collection supports the dynamic addition of keys and adds the key and new-value."

Next chapter: #11: Last-Setter (Addition)