Re: [Factor-talk] Finding words with given stack effect

2011-11-10 Thread John Benediktsson
Well, you could do this: ( scratchpad ) all-words [ stack-effect (( x p q -- )) effect= ] filter But, it only checks for arity (meaning it would match an effect (( a b c -- )) also). If you want to check the stack names in the effect, you can do this: : my-effect= ( effect1 effect2 --

Re: [Factor-talk] Finding words with given stack effect

2011-11-10 Thread P.
There's no formal method to search for those, like there is for Haskell (hoogle). I've asked this in the past and either erg or qx (can't remember who) came up with this: IN: scratchpad all-words [ stack-effect present ( n seq -- elt ) = ] filter --- Data stack: { nth-unsafe pull-out-nth nth }