tri-curry* ( x y z p q r -- p' q' r' )

Factor handbook » The language » Combinators » Compositional combinators » Curried dataflow combinators

Factor handbook » The language » Combinators » Compositional combinators » Curried dataflow combinators

Prev: | bi-curry* ( x y p q -- p' q' ) |

Next: | bi-curry@ ( x y q -- p' q' ) |

Vocabulary

kernel

Inputs

Outputs

Word description

Partially applies p to x, q to y and r to z.

Notes

The following two lines are equivalent:

The combination tri-curry* tri is equivalent to a stack shuffle preceding 2tri*:

Definition

kernel

Inputs

x | an object |

y | an object |

z | an object |

p | a quotation with stack effect ( x -- ... ) |

q | a quotation with stack effect ( y -- ... ) |

r | a quotation with stack effect ( z -- ... ) |

Outputs

p' | [ x p ] |

q' | [ y q ] |

r' | [ z r ] |

Word description

Partially applies p to x, q to y and r to z.

Notes

The following two lines are equivalent:

[ p ] [ q ] [ r ] tri-curry* [ call ] tri@
[ p ] [ q ] [ r ] tri*

The combination tri-curry* tri is equivalent to a stack shuffle preceding 2tri*:

[ p ] [ q ] [ r ] tri-curry* tri
[ [ over ] dip over ] dip [ p ] [ q ] [ r ] 2tri*

Definition