Warning: This is the manual of the legacy Guile 2.0 series. You may want to read the manual of the current stable series instead.
Next: SRFI-69 Table properties, Previous: SRFI-69 Creating hash tables, Up: SRFI-69 [Contents][Index]
Answer the value associated with key in table. If key is not present, answer the result of invoking the thunk default-thunk, which signals an error instead by default.
hash-table-ref/default
is a variant that requires a third
argument, default, and answers default itself instead of
invoking it.
Set key to new-value in table.
Remove the association of key in table, if present. If absent, do nothing.
Answer whether key has an association in table.
Replace key’s associated value in table by invoking modifier with one argument, the old value.
If key is not present, and default-thunk is provided, invoke it with no arguments to get the “old value” to be passed to modifier as above. If default-thunk is not provided in such a case, signal an error.
hash-table-update!/default
is a variant that requires the
fourth argument, which is used directly as the “old value” rather
than as a thunk to be invoked to retrieve the “old value”.