with-methods ( class generic quot -- )


Vocabulary
generic

Inputs and outputs
classa class
generica generic
quota quotation with stack effect ( methods -- )


Word description
Applies a quotation to the generic word's methods hashtable, and regenerates the generic word's definition when the quotation returns.

Notes
Calling this word directly is not necessary in most cases. Higher-level words call it automatically.

Definition
USING: kernel words ;

IN: generic

: with-methods ( class generic quot -- )
[ "methods" word-prop ] prepose [ update-generic ] 2bi ;
inline