Handbook
Glossary
assoc-merge ( assoc1 assoc2 quot: ( value1 value2 -- new-value ) -- new-assoc )
Vocabulary
assocs
.
extras
Inputs
assoc1
an
object
assoc2
an
object
quot
a
quotation
with stack effect
( value1 value2 -- new-value )
Outputs
new-assoc
an
object
Definition
USING:
kernel
;
IN:
assocs.extras
:
assoc-merge
( assoc1 assoc2 quot: ( value1 value2 -- new-value ) -- new-assoc )
pick
[
[
clone
]
2dip
assoc-merge!
]
[
drop
nip
]
if
;
inline